What type of inheritance that PHP supports?

Answers were Sorted based on User's Feedback



What type of inheritance that PHP supports?..

Answer / sharmila

PHP supports Multi-level inheritence.It wont support
multiple inheritence,but we can achieve multiple
inheritence through interfaces.

Is This Answer Correct ?    140 Yes 12 No

What type of inheritance that PHP supports?..

Answer / vikas sharma

PHP can support single,multilevel inheritance. And you can
use interfaces to achive multiple inheritace but not
directly multiple inheritance is allowed due to its
limitations

Is This Answer Correct ?    68 Yes 8 No

What type of inheritance that PHP supports?..

Answer / rakesh kumar nautiyal

As far PHP concern it only support single Inheritance in
scripting.

Is This Answer Correct ?    66 Yes 39 No

What type of inheritance that PHP supports?..

Answer / anendra patel

PHP support all inheritance(Single,Multilevel,Hierarchical,
and Hi breed) except Multiple inheritance.but we can achieve
multiple inheritance through INTERFACE.

Is This Answer Correct ?    36 Yes 11 No

What type of inheritance that PHP supports?..

Answer / dinesh

along with single,multilevel php also supports hierarchy

Is This Answer Correct ?    22 Yes 8 No

What type of inheritance that PHP supports?..

Answer / koushik samanta

phP SUPPORTS ONLY mULTILEVEL AND SINGLE iNHERUTANCES

Is This Answer Correct ?    29 Yes 17 No

What type of inheritance that PHP supports?..

Answer / mahesh

PHP can support single,multilevel,hierarchical and hybrid
inheritance but not multiple inheritence because of diamond problem.
Q:what is diamond problem?
A:suppose "class A extends class B and also class C".
then if class B contains function foo() and class C also contains function foo().if your creates object to the class A
and try to call function foo() then which class function it will take class A or Class B.. in this case diamond problem will be occur.
But we can avoid this problem through "INTERFACE".

Is This Answer Correct ?    12 Yes 1 No

What type of inheritance that PHP supports?..

Answer / kumar singh

all inhertance are supported but multiple not supported
and replace by interface used in php5

Is This Answer Correct ?    16 Yes 7 No

What type of inheritance that PHP supports?..

Answer / palaniraja.wordpress.com

you can also use interface to achieve multiple inheritance.

Is This Answer Correct ?    36 Yes 28 No

What type of inheritance that PHP supports?..

Answer / abdul ghafoor awan

What type of inheritance that php supports?
In PHP an extended class is always dependent on a single base class, that is, multiple inheritance is not supported. Classes are extended using the keyword 'extends'.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More PHP Interview Questions

Is md5() is breakable if yes than how?

1 Answers  


Write a select query that will be displayed the duplicated site name and how many times it is duplicated?

0 Answers  


How to write comment in php?

0 Answers  


What is foreach loop in php?

0 Answers  


What is csrf validation?

0 Answers  






How to parse configuration file in php?

0 Answers  


What is difference between static and constant?

0 Answers  


how to use http headers inside php? Write the statement through which it can be added?

0 Answers  


How to submit form without a submit button.

0 Answers  


how to uploade video in php????

1 Answers  


hi sir am kiran kumar finished my mca 2009 passed out sir .. i have more doubts regarding open source technologies sir if we pass zend exam in php can we get a job opportunity in foreign countries sir and is it good demand for php compared to dot net and java and some other technologies like sap , erp sir bcoz my friends saying they are finished dot net and java courses they telling in php we cannot earn more and we cannot go onsite opportunity even big companies not dealing with php is it right ah sir ? please send ur valuable suggestions to my email sir kiranpulsar2007@gmail.com please send ur phone number also sir thanking u sir

1 Answers  


How to create an array in php?

0 Answers  


Categories