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

Which sentence describes the following regular expression match?

preg_match('/^\d*(?:\.[0-9]+)?$/', $test);

A.

It matches float numbers with thousand separators.

B.

It matches float numbers without thousand separators.

C.

It matches binary integer numbers.

D.

It matches any string.

E.

It does not match anything

Consider the following code:

strspn($test, 'aeiou', 1);

The variable $test contains the string "You get certified".

What will the function call return?

A.

true

B.

false

C.

0

D.

1

E.

2

F.

3

An object can be counted with count() and sizeof() if it

A.

implements ArrayAccess

B.

has a public __count() method

C.

was cast to an object from an array

D.

None of the above

What is the length of a string returned by: md5(rand(), TRUE);

A.

Depends on the value returned by rand() function

B.

32

C.

24

D.

16

E.

64

What is the name of the PHP function used to automatically load non-yet defined classes?

A.

autoload()

B.

__autoload()

C.

__catch()

D.

load()

E.

loadClass()

Which string will be returned by the following function call?

$test = '/etc/conf.d/wireless';

substr($test, strrpos($test, '/'));

A.

""

B.

"/wireless"

C.

"wireless"

D.

"/conf.d/wireless"

E.

"/etc"

How can you determine if magic_quotes_gpc is enabled? (Choose 2)

A.

Use the get_magic_quotes() function.

B.

Using the get_magic_quotes_runtime() function.

C.

Use the get_magic_quotes_gpc() function.

D.

Using ini_get('magic_quotes_gpc').

E.

Using ini_get('magic_quotes').

How many elements does the array $matches from the following code contain?

1

2 $str = "The cat sat on the roof of their house.";

3

4 $matches = preg_split("/(the)/i", $str, -1,

PREG_SPLIT_DELIM_CAPTURE);

5 ?>

A.

2

B.

3

C.

4

D.

7

E.

9

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?

A.

header()

B.

headers()

C.

headers_list()

D.

headers_sent()

What piece of code would you use to obtain an array of response headers for a given URL, indexed by their respective names?

A.

get_headers($url);

B.

get_header($url);

C.

stream_context_get_headers($url);

D.

get_headers($url, 1);

E.

get_headers($url, ASSOC_HEADERS);