Session Variables

C

ChrisN

Hi there,

Two questions related to each other.

1. Session variables expire by defualt when not used for 20 minutes. Does
"used" mean that a user has not access any session varibles in 20 minutes or
that no pages activity has taken place in that time regardless of wether or
not a session variable has been accessed?

2. When a user logges in I store the user's ID in a session variable. This
variable is required on most but not all pages of my site. For security
reasons I can't store it in a cookie. Will there ever be a scenario where
the user is still looking at pages on the site when his session variable
expries?

Thanks,
Chris.
 
J

Juan T. Llibre

re: 1

Session variables expire when a user hasn't requested
any page from an application within the time limit set
for session expiration.

re: 2

A user may open pages after his session has expired,
but the session variables collection will be empty,
except for any session variables set in Session_OnStart
or the page the user opened, since a new session will
have been spawned after expiration of the session and
a subsequent opening of a page within the application.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,968
Messages
2,570,152
Members
46,697
Latest member
AugustNabo

Latest Threads

Top