Support for PHP 4 Ends – Plan Ahead for PHP 6

Published: August 15th, 2007 by:

Unfortunately for all of you that are to lazy to check and modify your code for PHP 5, your procrastinating days are drawing to a close. Support for PHP 4 ends on December 31, 2007. Ever since the PHP5 official release on July 13, 2004, the PHP group has been supporting both versions 4 and 5 together, allowing plenty of time for the developers to check and tweak their code. Now to review, the fact that they say they are not supporting it on their website does not mean that you won't be able to use it. It just means that you shouldn't expect any more updates. According to PHP's website, they won't be releasing any major updates to PHP 4.4 after this year, and they will be releasing critical updates on a case-by-case basis only until August 08, 2008.

I upgraded my commercial web server to run PHP 5 this last summer (’06) after running it on my development server several months before that. If you are behind me and still have yet to check your code for PHP 5, you might as well check for possible changes that are going to be made in PHP 6.

First, head on over to PHP’s guide to Migrating from PHP 4 to PHP 5. Once you clear your code to PHP 5 standards, put in the extra effort now to make sure you are ready for PHP 6 by not using any of the functions below as they will be removed.

  • register_globals will be no more. This feature was disabled by default in PHP 5 to encourage developers to merge away from it, but in PHP 6, it’s gone for good.
  • magic_quotes will be no more. This feature escaped all incoming data with in my opinion was annoying, so I disabled it on my websites and only escaped the data that needed to be.
  • safe_mode will be no more.
  • HTTP_*_VARS are gone. Use _POST, _GET, _COOKIE, _SESSION instead.
  • Returning reference will be removed.

See for more information on PHP 6.

Leave a Reply

Wordpress doesn't like it when you post PHP code. Go save your code at pastebin, and post the link here.

About the Author

Andrew has been coding PHP applications since 2006, and has plenty of experience with PHP, MySQL, and Apache. He prefers Ubuntu Linux on his desktop and has plenty of experience at managing CentOS web servers. He is the owner of Wells IT Solutions LLC, and develops PHP applications full time for anyone that needs it as well as does desktop computer support locally in the local area. He spends most of his free time exploring new programming concepts and posting on The Webmaster Forums.