3 Replies Latest reply on Oct 30, 2006 5:50 PM by GotJosh?

    Closing Session when Browser Closes

    Level 7
      Can anyone help me with closing out the session when the browser closes?

      I first started my project using a Application.cfm file. Then after further
      research found the newer method of using the Application.cfc file with
      cfcomponent tags instead.

      Using the newer Application.cfc method seems to not allow the following
      statements that would destroy the CFID and CFTOKEN cookies when the browser
      closes and generates a "Element CFID is undefined in SESSION" error message:

      <!---Preserve Session/Client variables only until browser closes--->
      <cfset Cookie.cfid = SESSION.cfid>
      <cfset Cookie.cftoken = SESSION.cftoken>

      What is the proper command/method of doing the same when using a
      Application.cfc file?

      I would also like to know how to test if the CFID and CFTOKEN cookies are
      actually being passed to the browser and to see them physically disappear
      after the browser closes.

      Thanks,
      Herb