1.

Which function was introduced to help automate the inclusion of class files?(a) __load()(b) __preload()(c) __autoload()(d) __inload()I had been asked this question in an interview for internship.Query is from Object Tools in chapter Object Tools and Design and Variables in PHP of PHP

Answer»

Correct choice is (c) __autoload()

Best explanation: When the PHP engine encounters an attempt to instantiate an unknown class, it invokes the __autoload() function, passing it the class name as a string. It is up to the IMPLEMENTER to define a strategy for locating and including the MISSING class file.



Discussion

No Comment Found

Related InterviewSolutions