Multilevel and Multiple inheritance in PHP

3569 2

PHP does not support multiple inheritance. PHP supports multileve inheritance. Child class class can’t inherit by more than one parent class. But Parent class inherit the properties of prand parend class and grand child can inherit the properties of parent class.
 Multiple inheritance in PHP

This code will not work in php because PHP does not support multiple Inheritance.
Multilevel inheritance in PHP

In the given example class2 inheriting the class1 and class3 inheriting the class2. So class3 have  some properties of class2 and some properties of class1.

In this article

Join the Conversation

  • Anand jain

    WOW just what I was searching for.

  • Abhishek

    I am regular visitor, how are you everybody? This paragraph posted at this site is genuinely fastidious.|