Chapter 9: Object oriented programming with PHP
Why objects?
Creating basic classes
Implementation of OOP
Implementation of OOP
Hello, you called my_method(MyParam)!
The value of my variable is 10
Private and Public
Private and Public
Constructors and Destructors
Class Constants
Static Methods
static function myMethod() {
... }
<CLASSNAME>::<METHOD>
Class Inheritance
Example inheritance
Class member overloading
Class Member Binding
Advanced classes
Example Abstract Classes
Interfaces
Implementing Interfaces
Final Classes and Methods
Special methods
Getters and Setters
function __get($name);
function __set($name, $value);
The __call() Method
function __call($method, $arguments);
Using the __call() Method
The __toString() Method
Using the __toString() Method
Class autoloading
function __autoload($classname);
Using the __autoload() Function