|
Another important capability of ASP is maintaining information specific
to individual users. In the previous step, you entered your name in a
form, and Sun ONE Active Server Pages stored it in what's called a Session
variable. This page uses the Session variable to display your name above.
The HTTP protocol is inherently stateless, which means that no information
about the user who is browsing the Web site is maintained from one Web
page to another. For many applications, however, knowing the state of
a user's interaction with an application is essential. Sun ONE Active
Server Pages overcomes this obstacle by creating a Session object that
holds all of a particular user's information.
Sessions are established when a client connects to the Sun ONE Active
Server Pages application, and end when explicitly abandoned or after a
time-out period configurable in the application has expired. The Session
object can hold just about any type of information that the programmer
deems necessary, such as personal user information.
Click Next to continue the tour. |