200-500 Exam Questions
241 real 200-500 exam questions with expert-verified answers and explanations. Page 2 of 5.
- Question #53
How can a SimpleXML object be converted to a DOM object?
- Question #54
What PHP function can be used to remove a local file?
- Question #55
What DOM method is used to load HTML files?
- Question #56
What is the output of the following script? 1 <?php 2 function fibonacci (&$x1 = 0, &$x2 = 1) 3 { 4 $result = $x1 + $x2; 5 $x1 = $x2; 6 $x2 = $result; 8 return $result; 9 } 11 for...
- Question #57
What will be the result of the following operation? array_combine(array("A","B","C"), array(1,2,3));
- Question #58
Which of the following functions can help prevent session fixation vulnerabilities?
- Question #59
How can you determine if magic_quotes_gpc is enabled? (Choose 2)
- Question #60
You want to present the following formatted number: "999.000.000,00". Which function call is correct?
- Question #61
What function returns the filename component of the file's path:
- Question #62
Which of the following are valid SoapClient calls? (Choose 2)
- Question #63
After performing the following operations: $a = array('a', 'b', 'c'); $a = array_keys(array_flip($a)); What will be the value of $a?
- Question #64
Which of the following statements about exceptions are correct? (Choose 2)
- Question #65
After executing a query on a database server, PHP offers several functions to read the resulting lines, such as mysqli_fetch_assoc, pg_fetch_row, oci_fetch,etc.). If such functions...
- Question #66
An unbuffered query will: (Choose 2)
- Question #67
What parsing methodology is utilized by the SimpleXML extension?
- Question #68
Which of the following is NOT possible using reflection?
- Question #69
Given the following two functions, what statement is correct? function dynamicNew($name) { return new $name; } function reflectionNew($name) { $r = new ReflectionClass($name); retu...
- Question #70
Which string will be returned by the following function call? $test = '/etc/conf.d/wireless'; substr($test, strrpos($test, '/'));
- Question #71
Which of the following statements about Reflection are correct? (Choose 2)
- Question #72
Which PHP function retrieves a list of HTTP headers that have been sent as part of the HTTP response or are ready to be sent?
- Question #73
In a shared hosting environment, session data can be read by PHP scripts written by any user. How can you prevent this?
- Question #74
Which is the most secure approach for handling dynamic data in SQL queries?
- Question #75
When PHP is running on a command line, what super-global will contain the command line arguments specified?
- Question #76
Which of the following did not result in an output error in PHP 4 but does in PHP 5?
- Question #77
How many elements does the array $matches from the following code contain? 1 <?php 2 $str = "The cat sat on the roof of their house."; 4 $matches = preg_split("/(the)/i", $str, -1,...
- Question #78
What function allows resizing of PHP's file write buffer?
- Question #79
Which of the following functions are used to escape data within the context of HTML? (Choose 2)
- Question #80
After running this sort, what will be the value of $b? $a = array('_!', 'def', 0); $b = sort($a);
- Question #81
Which of the following is an invalid DOM save method?
- Question #82
Can a private static member be accessed from a public static method of the same class?
- Question #83
Which of the following is NOT a valid function declaration?
- Question #84
What is the purpose of the 4th argument to the file_get_contents() function?
- Question #85
Which of the following commands will append data to an existing file?
- Question #86
Which of the following statements about SOAP is NOT true?
- Question #87
Which of the following XML declarations is NOT valid?
- Question #88
Which of the following configuration directives increase the risk of remote code injection when enabled? (Choose 2)
- Question #89
Which of the following is correct? (Choose 2) 1) A class can extend more than one class. 2) A class can implement more than one class. 3) A class can extend more than one interface...
- Question #90
Which of the following statements is NOT correct?
- Question #91
What tags can always be used to begin a PHP script (Choose 2)?
- Question #92
What will the following function call return?
- Question #93
What object method specifies post-serialization behavior for an object?
- Question #94
What is the purpose of the open_basedir directive?
- Question #95
What is the difference between "print" and "echo"
- Question #96
You analyze the code of a colleague and see a call to the function quotemeta(). You give the string "Holy $%&[. What's going on?" as a parameter to it. What will it output?
- Question #97
Which of the following keywords is not new in PHP 5?
- Question #98
Which of these protocols are NOT governed by the W3C in their latest versions? (Choose 2)
- Question #99
Which elements does the array returned by the function pathinfo() contain?
- Question #100
What is the output of the following code? $a = 1; ++$a; $a*=$a; echo $a--;
- Question #101
Which requirements need NOT be met so that file uploads work?
- Question #102
The following form is loaded in a recent browser and submitted, with the second list element selected: <form method="post"> <select name="list"> <option>one</option> <option>two</o...