From what I can remember, and it has been a while since I have used
CFcookie but since CFlocation does a header push to the browser that the
cookie doesn't get set if cfcookie is used prior to a cflocation.
I would suggest using session or client variables which set a cookie
anyways to keep state.
J.J. Merrick
Daniel Kessler wrote:
> I am using cookies to define whether a person is logged in.
> <cfif NOT isDefined('cookie.fsnep_login')>
> - no cookie
> - set return url
> - link to login page
> </cfif>
>
> click to go to the login, log in and it does:
> <cfset k = structDelete(cookie,'fsnep_login',true)>
> <cfcookie name="fsnep_login" value="#validate_user.login_id[1]#">
> <cflocation url="#the_return_url#">
>
> but when it returns to that url, the original code still fails and
> seems to think that you're not logged in. Oddly, if the return url
> is "../index.cfm" then it seems to work. Just not when it's coming
> from the other url. I tried refreshing the page to see if it was
> just not updating but that doesn't help.
>
> Please, any thoughts would help.
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Logware (www.logware.us): a new and convenient web-based time tracking
application. Start tracking and documenting hours spent on a project or with a
client with Logware today. Try it for free with a 15 day trial account.
http://www.houseoffusion.com/banners/view.cfm?bannerid=67
Message: http://www.houseoffusion.com/lists.cfm/link=i:4:213729
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe:
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54