Inheritance–the classical parent, child, and "is a" style
Inheritance describes the way that PHP allows us to create formal and hierarchical graphs of related objects with a single-parent, multiple-child structure.
Even if you decide to avoid ever using inheritance in your own, lovingly crafted PHP, you will not be able to avoid the fact that inheritance plays a huge role in the built-in classes and interfaces and is also a major feature of big, must-have libraries such as PHPUnit.
To get a full understanding of the PHP inheritance model, your first port of call should be the official documentation:
PHP Manual – Object Inheritance
https://www.php.net/manual/en/language.oop5.inheritance.php
Inheritance in OOP refers to the fact that a class can inherit properties and methods from a parent class.
Have a look at the very simple demonstration that follows, which demonstrates one-level inheritance and also illustrates what is and is not accessible...