Try 10 free questions below from the full 232-question premium file — answers and explanations included.
An unbuffered database query will: (Choose 2)
What is the output of the following code?$text = 'This is text';$text1 = <<<'TEXT'$text TEXT;$text2 = <<<TEXT$text1 TEXT;echo "$text2";
Is the following code vulnerable to SQL Injection ($mysqli is an instance of the MySQLi class)?$age = $mysqli->real_escape_string($_GET['age']);$name = $mysqli->real_escape_string($_GET['name']);$query = "SELECT * FROM `table` WHERE name LIKE '$name' AND age = $age";$results = $mysqli->query($query);
Which DOMElement property provides a reference to the list of the element's children?
Consider the following table data and PHP code, and assume that the database supports transactions. What is the outcome?Table data (table name "users" with primary key "id"):[email protected]@[email protected]@example.infoPHP code (assume the PDO connection is correctly established):$dsn = 'mysql:host=localhost;dbname=exam';$user = 'username';$pass = '********';$pdo = new PDO($dsn, $user, $pass);try {$pdo->exec("INSERT INTO users (id, name, email) VALUES (6, 'bill', '[email protected]')");$pdo->begin();$pdo->exec("INSERT INTO users (id, name, email) VALUES (7, 'john','[email protected]')");throw new Exception();} catch (Exception $e) {$pdo->rollBack();}
Please provide the value of the $code variable in the following statement to set an HTTP status code that signifies that the requested resource was not found.http_response_code($code);
Which sentence describes the following regular expression match? preg_match('/^\d+(?:\.[0-9]+)?$/', $test);
Which php.ini setting is usually required to use an opcode cache?
What DOMElement method should be used to check for availability of a non-namespaced attribute?
One common security risk is exposing error messages directly in the browser. Which PHP configuration directive can be disabled to prevent this?
You just tried 10 free questions. The full premium file has 232 questions with answers and explanations — PDF + Web-Based Practice Test.
Instant delivery • Free updates for life • Pass or your money back
View Full Details