Thread: cookie

    #1
  1. No Profile Picture
    pnoren
    Guest
    Devshed Newbie (0 - 499 posts)
    Im trying to set a cookie but fails the answer i get is that it have to be set before header...somone how knows how to do it?
    /P
  2. #2
  3. No Profile Picture
    AlexDG
    Guest
    Devshed Newbie (0 - 499 posts)
    You have to call SetCookie function BEFORE you make any output (ie HTML) to the browser

    ------------------
    Alex D. G.
    http://www.alexdg.com

  4. #3
  5. No Profile Picture
    pnoren
    Guest
    Devshed Newbie (0 - 499 posts)
    Thanks, I get it to work know but when a make a first check of the login-cookie after setting it, It does not find the cookie but if I try to login again and check a second time it finds it.
    Why?

    Does it have to be at timebreak(paus-swedish) between I set it and I check the cookie?
  6. #4
  7. No Profile Picture
    AlexDG
    Guest
    Devshed Newbie (0 - 499 posts)
    no pauses there.... the cookie becomes visible only after second execution of the code. First execution - cookies set in the browser, second cookie being read from and sent to the code.... i guess....

    ------------------
    Alex D. G.
    http://www.alexdg.com

Similar Threads

  1. Placing user-entered data into cookie
    By Tyrone in forum Perl Programming
    Replies: 2
    Last Post: February 17th, 2004, 04:31 PM
  2. ASPSESSIONID cookie seems to kill JavaScript cookie
    By cdarling in forum JavaScript Development
    Replies: 1
    Last Post: July 25th, 2003, 12:25 PM
  3. javascript - cookie based redirect... not working?
    By drgroove in forum JavaScript Development
    Replies: 4
    Last Post: July 4th, 2003, 01:55 AM
  4. can't get cookie from different directory
    By manjoufna in forum Perl Programming
    Replies: 2
    Last Post: April 9th, 2003, 04:11 PM
  5. Per session cookie expiration
    By csaba in forum PHP Development
    Replies: 4
    Last Post: June 21st, 2002, 09:54 PM

IMN logo majestic logo threadwatch logo seochat tools logo