PHP 5.3 new release

The new PHP textbooks being published are all trying to get a jump on the competition by talking about what we can expect in PHP 6.  PHP is the quietly taking the Internet by storm as the free open source, object-oriented, language of web development.

With that backdrop, the PHP development team quietly announced the release of PHP 5.3 on June 30, 2009 with no specific date for PHP6.  What are some of the new features in PHP5.3?

Although touted for PHP6, PHP now supports namespaces.  Namespaces allow you to group classes and variables in their own named area.  This helps with problems of duplicate naming causing bugs in large projects with multiple developers.

Of significant note, a MySQL native driver arrives to replace the MySQL Client Library.  This does not mean yet another MySQL API to learn, as it still uses PDO MySQL and MySQLi, but it has now become a part of PHP, instead of part of MySQL.  MySQL calls are now directly compiled with the MySQL Native driver instead of the MySQL Client Library.   This is more efficient by using the PHP Memory Management.  Before, each row retrieved from the database had to be stored twice in memory, once by the MySQL Client Library and once by PHP memory manaagement.  Now with the native driver, it only needs to be stored once. It also means that you can use PHP database calls without actually having MySQL installed.  This allows connections to become more persistent.  Added functions include a new mysqli_fetch_all() function which returns all rows of a query at once, as well as new statistical functions.

Some other features include: improved Windows support, late static bindings, garbage collection for circular references, and better MIME support.  There are over 140 bug fixes and overall improvements.  Compatiblity with the older PHP4 has now been dropped.

So what's still on the plate for PHP6, when it comes?  Full internationalization unicode UTF8 support.  Along with that, removal of the ereg regular expression extensions.  This further supports internationalization with regular expressions, and as an aside, it will help to cut down on some of the regular expression confusion, as to which extension to use.  Along with this we will see the disapperance of register_globals, magic_quotes and safe mode; and improved caching.

Comments

PHP 5.3 new release — 2 Comments