Quick Recursive Code Count

Although the “lines of code” in a project is not the worlds most useful metric. Curiosity sometimes gets the better of us and after many days / weeks of typing you think “gee I wonder exactly how many lines of code are in that project?”. Wonder no more! By embracing…

Read More

Logging PHP Errors For Production Environments

Good security practices dictate PHP should be configured to never display error messages and notices to screen in a production environment due to its potential to reveal information about your server and application setup. One solution is to enable error logging on the server by setting the log_errors attribute to 1 in your php.ini and reloading Apache. When active by default all errors will be sent to the Apache error log and will appear similar to the line below, unless a different path has been set in the php.ini configuration file using the error_log directive.


HTML5 Placeholders With jQuery

HTML 5 brings many new features to the browser including a lot of enhancements to the way forms are created and handled. One of my favourite features is the introduction of the placeholder attribute, this allows the display of  some text in a text input field or text area until the element is brought into focus. This allows the addition of small tips or related prompts to give the user a better understanding of what is required as input.

Removing The WordPress Toolbar

One thing that has caused me some grief since the release of WordPress 3.1 is the admin bar that appears up the top of the blog when you are logged in.

Call me a stick in the mud but I have never really used it since its introduction and on a few sites it has even gone as far as breaking the appearance of the template.


IE Browser Testing

Testing your web site layouts in IE is still unfortunately an essential part of development. Depending on your OS it can be an inconvienance, needed to load a virtual machine or similar running Windows to test in IE and even then you are limited with the versions of IE you can test in.

Enter the IE NetRenderer, simply type in the URL of the site to test and it will show you what it looks like in Internet Explorer version 5.5 though to 8 beta 2!

Read More