Programming - PHP

You Are Here :: Home > Programming > PHP- General Questions

 
37.

Which of the following regular expressions can be used to check the validity of an e-mail addresses??                          


A. ^[^@ ]+@[^@ ]+.[^@ ]+$ B. ^[^@ ]+@[^@ ]+.[^@ ]+$
C. $[^@ ]+@[^@ ]+.[^@ ]+^ D. $[^@ ]+@[^@ ]+.[^@ ]+^




38.

You wrote the following script to check of the right category: Correct category! Incorrect category! What will be the output of the program if value of 'cate' remains 5??                          


A. Correct category! B. Incorrect category!
C. Error due to use of invalid operator in line 6:'if ($cate==5)' D. Error due to incorrect syntax at line 8, 10, 12 and 14




39.

You are using sessions and session_register() to register objects. These objects are serialized automatically at the end of each PHP page and are de-serialized automatically on each of the following pages. Is this true or false??                          


A. TRUE B. False
C. BLANK D. BLANK




40.

Which of the following is not supported in PHP5??                          


A. Type Hinting B. Reflection
C. Magic Methods D. Multiple Inheritance




41.

How would you store order number (34) in an 'OrderCookie'??                          


A. setcookie('OrderCookie',34); B. makeCookie('OrderCookie',34);
C. Cookie('OrderCookie',34); D. OrderCookie(34);




42.

The following php variables are declared: $company = 'ABS Ltd'; $$company = ',Sydney'; Which of the following is not a correct way of printing 'ABS Ltd,Sydney'??                          


A. echo '$company $$company'; B. echo '$company ${$company}';
C. echo '$company ${'ABS Ltd'}'; D. echo '$company {$$company}';




« prev

1

2

3

4

5

6

7

8

9

next »

 
 



© 2013 freshersindia.in ® | Copyrights | Terms & Conditions
   Designed by Freshers India
Catch Us on