SEO, PHP and Javascript Web Dev

Search Engine Optimisation, Web Development and Network Administration Ramblings

-->
15  08 2006

Auto Hot Key

Thought I would write a post about one of the most useful tools I have come across - Auto Hot Key. This is an awesomely useful and powerful tool and I haven’t even scratched the surface, but it really comes in handy when programming, so that you can bust out the syntax for that foreach loop/switch statement/do-while just like nothing.

But my favourite use is for debugging. I can just jump to anywhere in my code, write site test;[enter] and I’m all ready to output that database result/globals array/object. With the following entry…

 :oc:site test;::
(
echo "[pre tag] style='color: red' ";
print_r($);
echo "[pre tag]";
) 

It will insert…

echo "[pre tag] style='color: red' ";
print_r($);
echo "[pre tag]"; 

Of course, this is the most simple use of this tool, you just need to browse the website a little to recognise the potential. Enjoy!

(replace the [pre] tags with actual pre tags by the way)

Share this Post:
  • Reddit
  • Sphinn
  • del.icio.us
  • Digg
  • e-mail
  • Mixx
  • Google
  • StumbleUpon

Related posts:

  1. Tip of the Week : Nested Ternary Statement PHP
  2. Kerberos General Information
  3. Dynamic URLS

No tags for this post.
« Robots.txt
Network Password Error Outlook 2003 »

2 Responses to “Auto Hot Key”

  1. Randomly googled your website… could you just use a function to do this? I have a function called debug() which does what you have mentioned…

  2. Correct! You can, the advantage of this technique would be not having to include that function in your code base I guess.

Leave a Reply

-->
  • Photography