Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > ASP General > Inconsistent cookie issue - IIS4

Reply
Thread Tools

Inconsistent cookie issue - IIS4

 
 
changed
Guest
Posts: n/a
 
      09-11-2003
I'm having an inconsistent problem involving cookies. I have attempted to
duplicate the OS/browser settings for the remote users in question but I
cannot seem to duplicate the problem in any OS (Mac, Linux, Windows). I've
gone over and visited one problem site and I couldn't get it to work by
playing with security and privacy settings in MSIE. Obviously there is a
setting somewhere but I can't find it.

I can duplicate the problem by commenting out the ASP code that sets a
particular cookie. I also didn't see the cookie get set on the problem
system when I was trouble-shooting. I can't have the problem system with me
when I code though.

I won't post the entire project, but here are the parts that seem to be
central to the problem...

<%
Response.Expires=-1
Response.AddHeader "Pragma", "no-cache"

response.cookies("epeid") = value '40 characters
response.cookies("epeid").Expires = dateadd("n", 7, date() & " " &
Time())
response.redirect redirectURL
%>

It works fine on my systems. It redirects on the problem systems, only they
act like the cookie doesn't exist. When I asked the computer to prompt me
for each cookie I never saw epeid. On my system when I ask for a prompt it
just stalls on that particular cookie.

The above code is executed before any headers are written.

Thanks for any advice!

--
Mike


 
Reply With Quote
 
 
 
 
changed
Guest
Posts: n/a
 
      09-16-2003
"changed" <(E-Mail Removed)> wrote in message
news:bjqo6i$ic6$(E-Mail Removed)...
> It works fine on my systems. It redirects on the problem systems, only

they
> act like the cookie doesn't exist. When I asked the computer to prompt me
> for each cookie I never saw epeid. On my system when I ask for a prompt

it
> just stalls on that particular cookie.


I found the problem. In this particular step I was writing a cookie with
ASP and then writing another cookie with JavaScript in the same page
request. Both cookies would be used immediately after the redirect. The
redirect would not work consistently with any machine although the chances
of success improved with newer/better machines. The ASP cookie didn't need
to be written in this step (I was doing it at every step, now it's done at
the first step) so I stopped writing it and everything works fine.

I think ASP cookies and JavaScript cookies don't get along if they are being
written in the same instance of a page request.

--
Mike


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
inconsistent performance issue on Vista X64bit =?Utf-8?B?Y2FuaXhz?= Windows 64bit 0 02-10-2007 04:46 PM
IIS4 application variable removal nutso fasst ASP General 10 10-30-2006 08:26 PM
NT IIS4.0 to 2003IIS6.0 Upgrade - ASP will not work Kevin Callanan ASP General 1 06-22-2005 03:53 AM
IIS4 TO IIS6 APP. MIGRATION JORGEMAL ASP General 1 11-10-2004 01:03 AM
APS3 / IIS4 Session wont persist Richard ASP General 2 09-23-2003 08:04 AM



Advertisments