Switching between C, JavaScript and PHP can mess you up a little

I just spent a good few minutes looking for a bug which was, really (as they usually are) really obvious.

This is the first time I’ve written any PHP in a good few weeks, and since then I’d been using C loads of even JavaScript a little.

Well, variables in PHP look $likeThis, while more likeThis in C or JavaScript.

The dollar sign is the clear difference, but (it seems) it’s easy to forget. Hopefully writing this post will help me to remember!

Leave a Reply