1. When a session ia active, PHP provides a special constant called
a. SID
b. CID
c. DID
d. None of them
Answer: (a).SID

2. If you want PHP to transparently handle passing session variables for you when cookies are not available, you have to configure
a. enable-trans-sid option
b. enable-track-vars option
c. disable-tans-vars option
d. Both a and b
Answer: (d).Both a and b

3. A special kind of a file that is located in filesystem of your browser and can be read and write from web server, is calls as
a. Session
b. Cookies
c. Script
d. All of them
Answer: (c).Script

4. Using $_SESSION, $HTTP_SESSION_VARS functions can be dangerous, so that you can use
a. session_destroy ( )
b. session_unset ( )
c. set ( )
d. None of them
Answer: (b).session_unset ( )

5. In PHP, cookies are set by using the
a. setcookie ( ) function
b. set ( ) function
c. cookie_set ( ) function
d. None of them
Answer: (a).setcookie ( ) function

6. www-authenticate mechanism works only under the
a. Apache web server
b. CGI servers
c. ISS servers
d. PWS servers
Answer: (a).Apache web server

7. What kind of session will maintain its identity as long as user stays within a site?
a. Cookie based session
b. Variable based session
c. Session
d. None of them
Answer: (b).Variable based session

8. A period of time during which a particular person, views a number of web pages at a particular machine is called as
a. Session
b. Cookies
c. Parsing
d. None of them
Answer: (a).Session

9. A function that takes no argument s and return a string, which is unique key corresponding to a particular session
a. session_name ( )
b. session_params ( )
c. session_id ( )
d. id ( )
Answer: (c).session_id ( )

10. Name, value, expire, patrh, httponly, domain, secure all of these are arguments of
a. session ( ) function
b. setcookie ( ) function
c. reset_cookie ( ) function
d. None of them
Answer: (b).setcookie ( ) function

Page 1 of 10