What's New In PHP 5.3 Chris Chubb, Code Gurus www.codegurus.com [email_address]
Migrating from PHP 5.2.x to PHP 5.3.x http://us.php.net/manual/en/migration53.php
See other guides for 4.x -> 5 or 5.1 -> 5.2
Some of these items are things that are new to 5.2, but of interest because 5.3 has modified their implementation.
Backward Incompatible Changes Object._toString()  used for string casting everywhere, so you can override it, in fact you MUST if you want to use it for any place you may treat an object like a string, like in an echo DEBUG statement. Objects still can't be indices of arrays though, for that you must provide your own unique instance hash or call spl_object_hash(), even if you know it's unique. (Or fake it out with an explicit string cast: $array[(string)$object]) realpath() is now fully platform independent.
Deprecations (2) You must now specifically cast objects as an array to use them in the array sort functions. (Do this anyway...)
magic methods __get, __set, __isset, __unset, and __call must always be public and can no longer be static.
The __call magic method is now invoked on access to private and protected methods. (Not just public any more. Self __call)
Deprecations (2) Oracle extension now requires at least Oracle 10. (I think this is a bad idea, too many legacy Oracle installations)
'goto' and 'namespace' are now reserved words. Do a string search in your code. More on these later
New stuff Many new more descriptive error messages, especially with class handling.
Date object moved into the core, and all supporting functions have also become objects. Timezone is inspected more for intervals, etc.
Functions with new optional parameters http://us.php.net/manual/en/migration52.parameters.php
Highlights: datetime can now do milliseconds in the format
cookie functions take "httponly" so they can't be accessed by XSS attacks.
xmlreader now lets you set the encoding directly for reading. No more stream encoding manually.
New Functions http://us.php.net/manual/en/migration52.functions.php

New Stuff In Php 5.3

  • 1.
    What's New InPHP 5.3 Chris Chubb, Code Gurus www.codegurus.com [email_address]
  • 2.
    Migrating from PHP5.2.x to PHP 5.3.x http://us.php.net/manual/en/migration53.php
  • 3.
    See other guidesfor 4.x -> 5 or 5.1 -> 5.2
  • 4.
    Some of theseitems are things that are new to 5.2, but of interest because 5.3 has modified their implementation.
  • 5.
    Backward Incompatible ChangesObject._toString() used for string casting everywhere, so you can override it, in fact you MUST if you want to use it for any place you may treat an object like a string, like in an echo DEBUG statement. Objects still can't be indices of arrays though, for that you must provide your own unique instance hash or call spl_object_hash(), even if you know it's unique. (Or fake it out with an explicit string cast: $array[(string)$object]) realpath() is now fully platform independent.
  • 6.
    Deprecations (2) Youmust now specifically cast objects as an array to use them in the array sort functions. (Do this anyway...)
  • 7.
    magic methods __get,__set, __isset, __unset, and __call must always be public and can no longer be static.
  • 8.
    The __call magicmethod is now invoked on access to private and protected methods. (Not just public any more. Self __call)
  • 9.
    Deprecations (2) Oracleextension now requires at least Oracle 10. (I think this is a bad idea, too many legacy Oracle installations)
  • 10.
    'goto' and 'namespace'are now reserved words. Do a string search in your code. More on these later
  • 11.
    New stuff Manynew more descriptive error messages, especially with class handling.
  • 12.
    Date object movedinto the core, and all supporting functions have also become objects. Timezone is inspected more for intervals, etc.
  • 13.
    Functions with newoptional parameters http://us.php.net/manual/en/migration52.parameters.php
  • 14.
    Highlights: datetime cannow do milliseconds in the format
  • 15.
    cookie functions take"httponly" so they can't be accessed by XSS attacks.
  • 16.
    xmlreader now letsyou set the encoding directly for reading. No more stream encoding manually.
  • 17.