Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to: Undeclare variables in Cold Fusion

Status
Not open for further replies.

Bammy217

Programmer
Sep 28, 2002
74
BE
hey Folks,

I'm trying to undeclare a variable or two in cold fusion, does any one know how to do this (as unfortunatly there is no such thing as a <cfUNset ....> tag and i do need one :( )

to be more specific, I'm using a stack of session variables (hosting multi-app out of one db) and when users are admins in more then one app I need to kill the old variables (please don't tell me to just reset them as this doesn't do it for me, as it screws up logging...)

please help!!
D. We never fail, we just find that the path to succes is never quite what we thought...
 
Not exactly sure what you want, you either have a variable or you dont, here is one way to get rid of a session variable:

<cfset session.var = &quot;whatever&quot;>

<cfscript>
StructDelete(session, &quot;var&quot;);
</cfscript>
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top