Overriding in Oops

In this tutorial, you will get a detailed concept about the method overriding in PHP with examples.



Overriding in Oops- PHP

Overriding means having two methods with the same arguments, but different implementation

Two or more methods having the same method name and same argument but in different class is known as overriding. it is also known as run time polymorphism, dynamic polymorphism, and dynamic binding.

 Method Overriding Example:

 

But this overriding concept does not support in PHP, So implementing polymorphism, interfaces and abstract class play important role in PHP.



Tags: ,