Logo name

Practical PHP Programming:Object-oriented programming

From IpbWiki

  • Currently5.00/5
Jump to: navigation, search

The object-oriented programming (OOP) paradigm has been around for many years now, although the degree to which it is support varies widely across languages. C++, for example, is object-oriented C, and, as some purists would say, implements more OOP functionality than even Java does.

Before PHP 5 came along, OOP support in PHP was quite flaky and more of a hack than a serious attempt. As a result the few that used it often regretted the choice, and it is not surprising that the whole system got a full rewrite in PHP 5 - it is now much more advanced and flexible, and should please just about everyone.

Topics covered in this chapter are:

  • Objects and classes defined
  • Class inheritance
  • Access control
  • Runtime type information
  • Abstract and final properties and functions
  • Constructors and destructors
  • Magic functions
Author's Note: If you have used OOP in PHP 4, I strongly recommend you read this entire chapter from start to finish - OOP has been massively redesigned in PHP 5, and is much more functional and feature-rich now.


Chapter contents


Next: Practical_PHP_Programming:Conceptual overview of object orientation

This page was last modified on 16 October 2006, at 12:35.  This page has been accessed 2,417 times.  Content is available under GNU Free Documentation License 1.2Disclaimers