|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Get inside! Sample the range of functionality easily built with JMSL Library for Time Series Data Analysis, Heat Maps, Portfolio Optimization, Monte Carlo Simulation, Stock Price Charting and more. Download Now! |
|
#1
|
|||
|
|||
|
Deleting Session Variables
When I hit a logout page is it possible to wipe out all session variables?
Thanks ryan |
|
#2
|
|||
|
|||
|
<cfset structClear( session ) />
__________________
Ask if you have a question, but also help answer questions that you have knowledge of! Thanks, Brian. How to Post a Question in the Forums |
|
#3
|
|||
|
|||
|
I use <cfset session.variable="value"> throughout the site, instead of say StructInsert(employee, "firstname", Form.firstname), maybe I'm not understanding the structClear function clearly.
|
|
#4
|
|||
|
|||
|
The session scope is a structure. To add keys to a structure, you don't have to use "structInsert()". You can, but you don't have to. You can also do:
<cfset myStruct.myKey = "whatever" /> Or <cfset myStruct["myKey"] = "whatever" /> Hope that helps, Brian |
|
#5
|
|||
|
|||
|
That clears things up, thanks.
|
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > ColdFusion Development > Deleting Session Variables |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|