ASP Session Scope

Domain Hosting image
Web Hosting
Dedicated server
ssl certificate
Web Design image
Email

To give a variable session scope, store it in the Session object by assigning a value to a named entry in the object. For example, the following commands store two new variables in the Session object.

Session ("First Name") - "Jeff"
Session ("Last Name") - "Smith"

To retrieve information from the session object, access the named entry by using the output directive (<,% =) or Response. Write. The following example uses the output directive to display the current value of Session ("First Name"):

Welcome <% = Session ("First Name") %>
You can store user preferences in the Session Object, and then access those preferences to determine what page to return to the user. For example, you can allow a user to specify a text only version of your content in the first page of the application and apply this choice on all subsequent pages that the user visits in this application.

<% If Session ("Screen Resolution") = "Low" Then %> This is the text version of the page
<% Else %> This is the multimedia version of the page.
<% End If %>



Domain Name Search

www.


Copyright (C) 2007. Web Domain design hosting. All rights reserved.