@madpilot makes

PHP 4 being put out to pasture

Ok, I might be a bit of a Rails zealot now, but I still have a sweet spot for PHP. For many years it was my language of choice, and even today, server hosting or legacy applications still means that I have to throw around the < ?php ?> tag.

I just read on the official PHP website, that as of the end of this year, PHP 4 will no longer be updated, bar crucial security patches. This is a big thing, as many web hosting companies still only support PHP 4 as it isn’t possible to run PHP 5 on the same apache server with out resorting to CGI or proxy work-arounds. This basically means that you have 5 months to make sure that your webiste runs on PHP 5.

The PHP website has a guide to migration, and luckily, most of the time things are fairly smooth. Were you might get in to trouble is the new object model. PHP 5 has a brand new, closer-to-real OOP model that isn’t always completely backwards compatible with it’s older sibling. For example, the __construct() method is called as a constructor, rather than function with the same same as the class as per PHP 4. PHP 5 also supports private, protected and public accessors and methods, as well as native XML and SOAP support.

At this point if, you may want to try running all of your websites as CGI scripts via the PHP5 interpreter to make sure that they can run ok, and if they do, start moving everything over to ensure a smooth transition.