> <cfif pagesecurity EQ 1 and (cookie.je_user_id) EQ "">
>       <cflocation url="default.asp">
> </cfif>
> 
> I must be interpreting it wrong as this error occurs:
> Element JE_USER_ID is undefined in COOKIE.
> 
> Must there be a cookie set before this code executes?

You're generally right, but test that cookie exists before checking its
value:

<cfif pagesecurity eq 1 and (not isDefined("cookie.je_user_id") or
cookie.je_user_id eq "")>

This basically says "if security is enabled and the cookie isn't present, or
if security is enabled and the cookie is blank, take action."


-Justin



~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-newbie/message.cfm/messageid:5027
Subscription: http://www.houseoffusion.com/groups/cf-newbie/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-newbie/unsubscribe.cfm

Reply via email to