Logo

Php Questions Set 20:

Quiz Mode

We can add single line comment by using

1
2
3
4

Solution:

Which version of PHP introduced the instanceof keyword?

1
2
3
4

Solution:

 Which one of the following regular expression matches any string containing zero or one p? 

1
2
3
4

Solution:

Which function is used to verify whether a variable contains a value?
 

1
2
3
4

Solution:

 


What is the full form of DNS?

1
2
3
4

Solution:

Which one of the following preg PHP function is used to do a find and replace on a string or an array? 

1
2
3
4

Solution:

 Which of the following statements can be used to add two months to the existing date? 

1
2
3
4

Solution:

Which one of the following is the right way to clone an object?

1
2
3
4

Solution:

 Which one of the following statements should be used to disable just the fopen(), and file() functions? 

1
2
3
4

Solution:

What is the output of the following PHP code?

<?php

$user = array("Ashley", "Bale", "Shrek", "Blank");

for ($x=0; $x < count($user); $x++) {

if ($user[$x] == "Shrek") continue;

printf ($user[$x]);

}

?>

1
2
3
4

Solution: