You should be able to use the CreateTimeSpan function for the expires
attribute.
IE EXPIRES="#CreateTimeSpan(0,0,5,0)#"
This will set it to expire in 5 minutes.
----- Original Message -----
From: "Art Broussard" <[EMAIL PROTECTED]>
To: "CF-Talk" <[EMAIL PROTECTED]>
Sent: Thursday, November 30, 2000 10:24 AM
Subject: expire cookie in 5min
> This is a multi-part message in MIME format.
>
> ------=_NextPart_000_0073_01C05AB7.C1924EC0
> Content-Type: text/plain;
> charset="iso-8859-1"
> Content-Transfer-Encoding: quoted-printable
>
> I want to set a cookie to expire in 5 min. Can some body show me the =
> right way to set a cookie to expire in 5min?
>
> I dont know how to check when a cookie is set to expire so I dont know =
> if this is right.
>
> <cfcookie name=3D"5min"=20
> value=3D"what ever"=20
> expires=3D"#TimeFormat(DateAdd("n", 5, Now()), "hh:mm:ss")#">
>
> Does this need to have the date set also?
>
> thanks
>
> Art
>
> ------=_NextPart_000_0073_01C05AB7.C1924EC0
> Content-Type: text/html;
> charset="iso-8859-1"
> Content-Transfer-Encoding: quoted-printable
>
> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
> <HTML><HEAD>
> <META http-equiv=3DContent-Type content=3D"text/html; =
> charset=3Diso-8859-1">
> <META content=3D"MSHTML 5.50.3825.1300" name=3DGENERATOR>
> <STYLE></STYLE>
> </HEAD>
> <BODY bgColor=3D#ffffff>
> <DIV><FONT face=3DArial size=3D2>I want to set a cookie to expire in 5 =
> min. Can some=20
> body show me the right way to set a cookie to expire in =
> 5min?</FONT></DIV>
> <DIV><FONT face=3DArial size=3D2></FONT> </DIV>
> <DIV><FONT face=3DArial size=3D2>I dont know how to check when a cookie =
> is set to=20
> expire so I dont know if this is right.</FONT></DIV>
> <DIV><FONT face=3DArial size=3D2></FONT> </DIV>
> <DIV><FONT face=3DArial size=3D2><cfcookie =
> name=3D"5min" </FONT></DIV>
> <DIV><FONT face=3DArial size=3D2>value=3D"what ever" </FONT></DIV>
> <DIV><FONT face=3DArial size=3D2>expires=3D"#TimeFormat(DateAdd("n", 5, =
> Now()),=20
> "hh:mm:ss")#"></FONT></DIV>
> <DIV><FONT face=3DArial size=3D2></FONT> </DIV>
> <DIV><FONT face=3DArial size=3D2>Does this need to have the date set=20
> also?</FONT></DIV>
> <DIV><FONT face=3DArial size=3D2></FONT> </DIV>
> <DIV><FONT face=3DArial size=3D2>thanks</FONT></DIV>
> <DIV><FONT face=3DArial size=3D2></FONT> </DIV>
> <DIV><FONT face=3DArial size=3D2>Art</FONT></DIV></BODY></HTML>
>
> ------=_NextPart_000_0073_01C05AB7.C1924EC0--
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at
http://www.fusionauthority.com/bkinfo.cfm
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists