By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
448,781 Members | 1,470 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 448,781 IT Pros & Developers. It's quick & easy.

cookie testing

P: n/a
I need to revisit cookie testing. On the home page and every product page I
write a cookie. I do this because some users enter by direct links to
product pages.

<%
Response.Cookies("cookietest") = ("49")
Response.Cookies("cookietest").Expires = Date + 2
%>

On the cart page I test for the cookie...

<%
If Request.Cookies("cookietest") <"49" Then
Response.Redirect("err.asp?e=1")
End If
%>

I have a user that insists he has cookies enabled, yet he keeps getting
redirected to my error page which suggests he does not have cookies enabled.
What could cause this? Is the above too simple for all circumstances?

Is there more extensive code that I could setup on a hidden page where I can
send users to get read out on how they actually have their browsers setup?
i.e. Run a test on their browser and the results are emailed to me.

thanks!
Aug 30 '06 #1
Share this Question
Share on Google+
1 Reply


P: n/a
Jay
Whenever i use cookies, i ues this....
Response.Cookies("cookietest") = "49"
Response.Cookies("cookietest").Expires = Date + 2
Try that, it might help i hope
James Jones


"shank" <sh***@tampabay.rr.comwrote in message
news:OB**************@TK2MSFTNGP04.phx.gbl...
>I need to revisit cookie testing. On the home page and every product page I
write a cookie. I do this because some users enter by direct links to
product pages.

<%
Response.Cookies("cookietest") = ("49")
Response.Cookies("cookietest").Expires = Date + 2
%>

On the cart page I test for the cookie...

<%
If Request.Cookies("cookietest") <"49" Then
Response.Redirect("err.asp?e=1")
End If
%>

I have a user that insists he has cookies enabled, yet he keeps getting
redirected to my error page which suggests he does not have cookies
enabled. What could cause this? Is the above too simple for all
circumstances?

Is there more extensive code that I could setup on a hidden page where I
can send users to get read out on how they actually have their browsers
setup? i.e. Run a test on their browser and the results are emailed to me.

thanks!

Aug 30 '06 #2

This discussion thread is closed

Replies have been disabled for this discussion.