1.  What will be the output of the following PHP code ?
function foo($msg)
{
echo ‘‘$msg’‘;
}
$var1 = ‘‘foo’‘;
$var1(‘‘will this work’‘);
?>


Error
$msg
0.
will this work


Answer

 Option

It is possible to call a function using a variable which stores the function name.

Workspace

Report
Mail id: Report Error:

Answer Workspace Report

2.  What will be the output of the following PHP code ?
< ?php
echo lcfirst(''welcome to PrintExam'');
?>


welcome to PrintExam
welcome to printexam
Welcome to PrintExam
Welcome to printExam


Answer

 Option

The lcfirst() function converts the first character of a string to lowercase.

Workspace

Report
Mail id: Report Error:

Answer Workspace Report

3.  Which of the following PHP functions can be used for generating unique id’s ?


uniqueid()
id()
md5()
mdid()


Answer

 Option

Many people use the md5() function for this, even though it’s not exactly meant for this purpose. uniqueid() is the function that is to be used.

Workspace

Report
Mail id: Report Error:

Answer Workspace Report

4.  Which function sets the file filename’s last-modified and last-accessed times ?


sets()
set()
touch()
touched()


Answer

 Option

No answer description available for this question.

Workspace

Report
Mail id: Report Error:

Answer Workspace Report

5.  Which function is useful when you want to output the executed command’s result ?


out_cmm()
out_system()
cmm()
system()


Answer

 Option

No answer description available for this question.

Workspace

Report
Mail id: Report Error:

Answer Workspace Report