Debugging an Array – Print it Recursively with print_r()

Nice and simple one.. If you want to see whats in an entire array, use the print_r function. This will give you a nicely formatted output of the array showing all dimensions. Try it: {code type=php}$anArray = array(0=>’cheese’,1=>’bacon’,2=>’apples’); print_r($anArray); {/code} Tip if you are viewing this via the output of a webpage, view the source…

MySQL Password Function – OLD_PASSWORD() and PASSWORD()

The PASSWORD() function in MySQL can generate a hash value for encrypted passwords, similar to md5() in PHP. It is generally not recommended to use this function in an application as it is not particularly secure – it is intended for internal use. If, however, your application uses the MySQL PASSWORD() function, you need to…

Take Regular Backups

This is advice that you will have heard many times before… but please, for your sake, ensure that you have proper backups in place. As you well know, all our work and effort can disappear with unbelievable ease. Knock that Monday morning cup of coffee over your portable hard drive that contains the only copy…