kill cookie on browser close

View: New views
4 Messages — Rating Filter:   Alert me  

kill cookie on browser close

by Chad Gray-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


Anyone notice that in IE this codes does not appear to work anymore?  Firefox it works just fine.

I don't think it is just my browser... I have tried another computer with IE8 and it does not kill the session cookie.


<!--- if the user closes their browser, make sure all session variables get killed --->
<cfif isdefined("Cookie.CFID") and isdefined("Cookie.CFTOKEN")>
        <cfset cfid_local = cookie.cfid>
        <cfset cftoken_local = cookie.cftoken>
        <cfcookie name="CFID" value="#cfid_local#">
        <cfcookie name="CFTOKEN" value="#cftoken_local#">
</cfif>


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Want to reach the ColdFusion community with something they want? Let them know on the House of Fusion mailing lists
Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:328303
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=17837.14401.4

Re: kill cookie on browser close

by Dan G. Switzer, II :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


Chad,

Make sure you don't have any instances of IE open--including things that
might use the IE underneath (like an RSS reader, etc.)

-Dan

On Thu, Nov 12, 2009 at 11:39 AM, Chad Gray <cgray@...> wrote:

>
> Anyone notice that in IE this codes does not appear to work anymore?
>  Firefox it works just fine.
>
> I don't think it is just my browser... I have tried another computer with
> IE8 and it does not kill the session cookie.
>
>
> <!--- if the user closes their browser, make sure all session variables get
> killed --->
> <cfif isdefined("Cookie.CFID") and isdefined("Cookie.CFTOKEN")>
>        <cfset cfid_local = cookie.cfid>
>        <cfset cftoken_local = cookie.cftoken>
>        <cfcookie name="CFID" value="#cfid_local#">
>        <cfcookie name="CFTOKEN" value="#cftoken_local#">
> </cfif>
>
>
>

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Want to reach the ColdFusion community with something they want? Let them know on the House of Fusion mailing lists
Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:328306
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=17837.14401.4

RE: kill cookie on browser close

by Chad Gray-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


Must be something on my end.  The production server this code does not work in IE and the dev server it does work in IE.

Strange.

> -----Original Message-----
> From: Chad Gray [mailto:cgray@...]
> Sent: Thursday, November 12, 2009 11:40 AM
> To: cf-talk
> Subject: kill cookie on browser close
>
>
> Anyone notice that in IE this codes does not appear to work anymore?
> Firefox it works just fine.
>
> I don't think it is just my browser... I have tried another computer with
> IE8 and it does not kill the session cookie.
>
>
> <!--- if the user closes their browser, make sure all session variables
> get killed --->
> <cfif isdefined("Cookie.CFID") and isdefined("Cookie.CFTOKEN")>
> <cfset cfid_local = cookie.cfid>
> <cfset cftoken_local = cookie.cftoken>
> <cfcookie name="CFID" value="#cfid_local#">
> <cfcookie name="CFTOKEN" value="#cftoken_local#">
> </cfif>
>
>
>

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Want to reach the ColdFusion community with something they want? Let them know on the House of Fusion mailing lists
Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:328308
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=17837.14401.4

RE: kill cookie on browser close

by Chad Gray-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


Ah.. interesting.  I use Rhapsody that I believe uses IE.  I will close all applications and try again.

Thanks,
chad

> -----Original Message-----
> From: Dan G. Switzer, II [mailto:dswitzer@...]
> Sent: Thursday, November 12, 2009 12:36 PM
> To: cf-talk
> Subject: Re: kill cookie on browser close
>
>
> Chad,
>
> Make sure you don't have any instances of IE open--including things that
> might use the IE underneath (like an RSS reader, etc.)
>
> -Dan
>
> On Thu, Nov 12, 2009 at 11:39 AM, Chad Gray <cgray@...> wrote:
>
> >
> > Anyone notice that in IE this codes does not appear to work anymore?
> >  Firefox it works just fine.
> >
> > I don't think it is just my browser... I have tried another computer
> with
> > IE8 and it does not kill the session cookie.
> >
> >
> > <!--- if the user closes their browser, make sure all session variables
> get
> > killed --->
> > <cfif isdefined("Cookie.CFID") and isdefined("Cookie.CFTOKEN")>
> >        <cfset cfid_local = cookie.cfid>
> >        <cfset cftoken_local = cookie.cftoken>
> >        <cfcookie name="CFID" value="#cfid_local#">
> >        <cfcookie name="CFTOKEN" value="#cftoken_local#">
> > </cfif>
> >
> >
> >
>
>

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Want to reach the ColdFusion community with something they want? Let them know on the House of Fusion mailing lists
Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:328314
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=17837.14401.4