Search Header Logo

Cookies and Sessions

Authored by Tamal Dey

Computers

University

Used 59+ times

Cookies and Sessions
AI

AI Actions

Add similar questions

Adjust reading levels

Convert to real-world scenario

Translate activity

More...

    Content View

    Student View

10 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

The session_start() function must appear..

after the html tag

after the body tag

before the body tag

before the html tag

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which one of the following is the very first task executed by a session enabled page?

Delete the previous session

Start a new session

Check whether a valid session exists

Handle the session

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which one of the following is the default PHP session name?

PHPSESSID

PHPSESID

PHPSESSIONID

PHPIDSESS

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

If the directive session.cookie_lifetime is set to 3600, the cookie will live until..

3600 sec

3600 min

3600 hrs

the browser is restarted

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which one of the following function is used to start a session?

start_session()

session_start()

session_begin()

begin_session()

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which function is used to erase all session variables stored in the current session?

session_destroy()

session_change()

session_remove()

session_unset()

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What will the function session_id() return is no parameter is passed?

Current Session Identification Number

Previous Session Identification Number

Last Session Identification Number

Error

Access all questions and much more by creating a free account

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Classlink

Continue with Classlink

Clever

Continue with Clever

or continue with

Microsoft

Microsoft

Apple

Apple

Others

Others

Already have an account?