PHP Object Oriented Programming #3 - Inheritance and the Protected Scope
In the third video tutorial of this ten part series on Object Oriented PHP Programming, I show you how we can inherit functionality from a parent class by extending that class. In doing so, we create a parent Pet class and extend it to create a Dog and Cat class. In doing so, we walk through creating parameters as protected instead of private. We conclude the tutorial looking at constructors in child objects and calling parent constructors.