Video: Getting Started with Object-Oriented PHP

Although PHP wasn't conceived as an object-oriented language, its soaring popularity in the years following its initial release caused the developers to reconsider this decision. The decision to add object-oriented features in later releases was made in order to provider users with more sophisticated options for managing larger and more complex applications. However, to this day PHP remains a hybridized language, allowing both procedural and object-oriented programming. This flexibility has largely been a net positive because novice programmers generally find PHP to be the least intimidating of today's mainstream languages.

However, any novice programmer intent on building and maintaining a relatively complex PHP-driven website will almost certainly want to use a framework such as the Zend Framework, symfony or CakePHP. Because these frameworks are all object-oriented, developers lacking basic knowledge of PHP's object-oriented syntax will find themselves at a serious disadvantage. There's nothing to worry about though, as the syntax is every bit as straightforward as the rest of the language!

In the first of a two-part video series, you'll be introduced to PHP's object-oriented syntax, learning how to create a class, and populate it with class attributes and methods. You'll also learn how to access and manipulate object data, and create a constructor useful for initializing class data.

Please enable Javascript in your browser, before you post the comment! Now Javascript is disabled.