Weekend Sale Limited Time 70% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: xmas50

Zend 200-710 - Zend Certified Engineer

Page: 2 / 3
Total 75 questions

Which of the following will set a 10 seconds read timeout for a stream?

A.

ini_set(“default_socket_timeout”, 10);

B.

stream_read_timeout($stream, 10);

C.

Specify the timeout as the 5th parameter to the fsockopen() function used to open a stream

D.

stream_set_timeout($stream, 10);

E.

None of the above

Which of the following techniques ensures that a value submitted in a form can only be yes or no?

A.

Use a select list that only lets the user choose between yes and no.

B.

Use a hidden input field that has a value of yes or no.

C.

Enable the safe_mode configuration directive.

D.

None of the above.

What is the output of the following code?

A.

This is text

B.

$text

C.

$text1

D.

$text2

What is the benefit of using persistent database connections in PHP? (Choose two.)

A.

Reduces the connection & authentication overhead of connecting to the database

B.

Ensures that only a single connection is open to the database from PHP

C.

Allows connection settings such as character set encoding to persist

D.

Allows for resumption of transactions across multiple requests.

Given a DateTime object that is set to the first second of the year 2017, which of the following samples will correctly return a date in the format ‘2017-01-01 00:00:01’?

A.

$datetime->format(‘%Y-%m-%d %h:%i:%s’)

B.

$datetime->format(‘%Y-%m-%d %h:%i:%s’, array(‘year’, ‘month’, ‘day’, ‘hour’, ‘minute’, ‘second’))

C.

$datetime->format(‘Y-m-d H:i:s’)

D.

$date = date(“Y-m-d H:i:s’, $datetime);

What method can be used to find the tag via the DOM extension?

A.

getElementById()

B.

getElementsByTagName()

C.

getElementsByTagNameNS()

D.

getElementByName()

E.

findTag()

Consider 3 PHP files that are called asynchronously via XmlHttpRequest:

Which of the following statements is true? (Choose two.)

A.

The total execution time for all 3 requests will be the maximum of the longest sleep() call

B.

The requests may be processed out of order

C.

The requests are guaranteed to be executed in order

D.

Concurrent requests will be blocked until the session lock is released

An unbuffered database query will (choose two):

A.

return the first data faster

B.

return all data faster

C.

free connection faster for others scripts to use

D.

use less memory

You work for a shared hosting provider, and your supervisor asks you do disable user scripts to dynamically load PHP extensions using the d1() function. How can you do this? (Choose two.)

A.

Set enable_d1 to off in the server’s php.ini configuration file

B.

Add d1 to the current value of disable_functions in the server’s php.ini configuration file.

C.

Add d1 to the current value of disable_classes in the server’s php.ini configuration file.

D.

Write a custom function called d1(), save it under the name prepend.inc and then set the auto_prepend_file directive to prepend.inc in php.ini.

An HTML form contains this form element:

When this form is submitted, the following PHP code gets executed:

Which of the following actions must be taken before this code may go into production? (Choose two.)

A.

Check with is_uploaded_file() whether the uploaded file $_FILES[‘myFile’][‘tmp_name’] is valid.

B.

Sanitize the file name in $_FILES[‘myFile’][‘name’] because this value is not consistent among web browsers.

C.

Check the charset encoding of the HTTP request to see whether it matches the encoding of the uploaded file.

D.

Sanitize the file name in $_FILES[‘myFile’][‘ name’] because this value could be forged.

E.

Use $HTTP_POST_FILES instead of $_FILES to maintain upwards compatibility.