1.

Which one of the following is the right description for the method getMessage()?(a) Returns the message if it is passed to the constructor(b) Returns the message if it is passed to the class(c) Returns the message if it is passed to the file(d) Returns the message if it is passed to the objectThe question was asked during an online exam.This intriguing question originated from Exception Handling topic in chapter Error Handling and Exception Handling in PHP of PHP

Answer»

The correct answer is (a) Returns the message if it is passed to the CONSTRUCTOR

To explain: The function GETMESSAGE() GETS the EXCEPTION message. It returns the message if it is passed to the constructor.



Discussion

No Comment Found

Related InterviewSolutions