Accessibility
 
Home > Products > UltraDev > Support > Building Common Applications
Dreamweaver UltraDev Icon Macromedia Dreamweaver UltraDev Support Center - Building Common Applications
Gathering the information to store in session variables

Before creating a session variable, you must gather the information you want to store in the variable, then send it to the server for storage. This article describes how to gather and send information to the server using one of two methods: HTML forms or hypertext links containing URL parameters.

You can also gather information from cookies stored on the user's computer, from the HTTP headers sent by the user's browser with a page request, and from a database.

Here's an example of a product catalog that uses hard-coded URL parameters appended to a hypertext link to send product information back to the server to be stored in a session variable:

The product number, 3202, will be stored in the session variable while the user continues to shop. When the user proceeds to the check-out page, the product number stored in the session variable will be retrieved.

Here's an example of a quiz page that uses a form to send information back to the server:

The marks.cfm page on the server scores the quiz and stores the number of right answers in a session variable.

Note: A page can submit information to a copy of itself on the server.

To Table of Contents Back to Previous document Forward to next document