Inconsistent cookie issue - IIS4

Discussion in 'ASP General' started by changed, Sep 11, 2003.

  1. changed

    changed Guest

    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
    changed, Sep 11, 2003
    #1
    1. Advertising

  2. changed

    changed Guest

    RESOLVED - Re: Inconsistent cookie issue - IIS4

    "changed" <> wrote in message
    news:bjqo6i$ic6$...
    > 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
    changed, Sep 16, 2003
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Ben
    Replies:
    3
    Views:
    5,831
    Steven Cheng[MSFT]
    Jun 3, 2004
  2. Richard

    APS3 / IIS4 Session wont persist

    Richard, Sep 22, 2003, in forum: ASP General
    Replies:
    2
    Views:
    156
    Richard
    Sep 23, 2003
  3. JORGEMAL

    IIS4 TO IIS6 APP. MIGRATION

    JORGEMAL, Oct 29, 2004, in forum: ASP General
    Replies:
    1
    Views:
    164
    Microsoft News
    Nov 10, 2004
  4. Kevin Callanan

    NT IIS4.0 to 2003IIS6.0 Upgrade - ASP will not work

    Kevin Callanan, Jun 22, 2005, in forum: ASP General
    Replies:
    1
    Views:
    156
    Ray Costanzo [MVP]
    Jun 22, 2005
  5. nutso fasst

    IIS4 application variable removal

    nutso fasst, Oct 21, 2006, in forum: ASP General
    Replies:
    10
    Views:
    258
    upmendez
    Oct 30, 2006
Loading...

Share This Page