Odesk HTML Tests and Solutions
What will be the output of the following code?
for ($i = 0; $i <>
{if($i == 2)
continoue;
print "$i\n";
}
?>
a. 0
1
2
3
4
5
b. 0
1
2
3
4
c. 2
d. 0
1
2
4
e. non of the above
Solution: B
Which of the following functions do you need to implement HTTP Basic Authentication?
a. Authenticate()
b. header()
c. basic_auth()
d. Non of the above
Does PHP support exceptions?
a. Yes
b. No
Which of the following are file PHP file Upload Related function?
a. upload_file()
b. is_upload_file()
c. move_upload_file()
d. Non of the above
Which of the following is not represent logical AND operator in PHP?
a. &
b. &&
c. And
d. AND
What will be the output of the following code?
$a = 10;
echo "Value of a = $a";
a. value of a = 10
b. Value of a = $a
c. Undefind
d. Syntax Error
with
reference to the folowing php script:
what
will be the output on running the script?
a.
Text Line 1Text Line 2
b. Text Line 1 Text Line 2
c.
'Text Line 1'
d. 'Text Line 2' e. error message
will b printed.
Solution:
E
Which of thew
following is not a correct way of printing text in PHP5?
a.
echo "plain text" ;
?>
b.
echo "plain text"
?>
c.
d. <# echo
"plain text" #>
If
you want to pass a value to a function by reference, the correct way
is:
a.
function ModifyReport(&$Rptfile){}
b.
function ModifyReport($Rptfile){}
c.
function ModifyReport(ByRef $Rptfile){}
d.
function ModifyReport(&Rptfile){}
What
would b the outpur of the following code?
$string
= 'good day';
$string
= ucword($string);
echo
$string;
?>
a. good
day
b. GOOD
DAY
c. Good
Day
d. non
of the above
The
default value of register global in PHP is:
a. Off
b. On
What is the
result of the following Exprssion?
5+2*4+6
a. 70
b. 19
c. 34
d. 21
Which one
of the following is turnary operator?
a. &
b. =
c. :?
d. ?:
e. +=
f.
&&
Not enough answer here, so if you want to get 23+ odesk test answer please test my site. Thanks
ReplyDelete