Oct 16, 2014

What are the differences between PHP3, PHP4, PHP5, and PHP6 ?

There are lot of difference among PHP3 and PHP4 and PHP5 version of php as PHP6 is till in under development process so we are geting Difference mean oldest version have less functionality as compare to new one like below points
  • A> PHP3 is oldest stable version and it was pure procedural language constructive like C
  • B> Where as PHP4 have some OOPs concept added like class and object with new functionality
  • C> and in PHP5 approximately all major oops functionality has been added along with below thing
  • 1. Implementation of exceptions and exception handling
  • 2. Type hinting which allows you to force the type of a specific argument
  • 3. Overloading of methods through the __call function
  • 4. Full constructors and destructors etc through a __constuctor and __destructor function
  • 5. __autoload function for dynamically including certain include files depending on the class you are trying to create.
  • 6 Finality : can now use the final keyword to indicate that a method cannot be overridden by a child. You can also declare an entire class as final which prevents it from having any children at all.
  • 7 Interfaces & Abstract Classes
  • 8 Passed by Reference :
  • 9 An __clone method if you really want to duplicate an object
  • 10 Numbers of Functions Deprecated or removed in PHP 5.x like ereg,ereg_replace,magic_quotes, session_register,register_globals, split(), call_user_method() etc   


Post a Comment