Lasso Soft Inc. > Home

[Session_AddVar]

[Session_AddVar] adds a variable to a specified session.

Accepts two parameters: -Name is the name of the session and a second unnamed parameter is the name of the variable.

At the end of the current page the value of the variable will be stored in the current session. When the session is next recalled with [Session_Start] the value of the stored variable will be restored.

Once a variable has been added to a session it's value will continue to be remembered in each page the session is loaded until a [Session_RemoveVar] tag is called.

Note: [Session_AddVar] does not automatically create the named variable.

  • Syntax
  • Parameters
[Session_AddVar: -Name='Session Name', 'Variable Name']
Required Parameters
-Name The name of the session to which the variable should be added.
Variable Name The name of the variable to add to the session.
Examples

To add a variable to a server-side session:

Use the [Session_AddVar] tag. The following example creates a session named ShoppingCart and adds two variables, TotalCost and TotalShipping.

[Session_Start: -Name='ShoppingCart', -Expires=1440, -UseCookie]
[Session_AddVar: -Name='ShoppingCart', 'TotalCost']
[Session_AddVar: -Name='ShoppingCart', 'TotalShipping']
Tag Link [Session_AddVar] Category Session
Type Process Data Source Any
Support Abbreviation Version 5.0
Output Type None Security None
Implementation Internal Sets Lasso 6.0, Lasso 5.0

Please note that periodically LassoSoft will go through the notes and may incorporate information from them into the documentation. Any submission here gives LassoSoft a non-exclusive license and will be made available in various formats to the Lasso community.

LassoSoft Inc. > Home

 

 

©LassoSoft Inc 2015 | Web Development by Treefrog Inc | PrivacyLegal terms and Shipping | Contact LassoSoft