SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Member
    Join Date
    Jun 2001
    Posts
    22
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Problem with cookies

    I am storing the user name,user type in a cookie after logging in and the appropriate access is given to the users depending on their privileges.

    So after the password confimation, I am setting the cookies and redirecting to the main page. But I can't read the cookies from the redirected main page.

    For starters, I am unable to print the cookie using
    echo $cookiename;
    echo $HTTP_COOKIE_VARS["cookiename"];

    Do I have to set something else or am I doing it correctly ?

    Thanx

  2. #2
    SitePoint Enthusiast
    Join Date
    Jun 2001
    Posts
    83
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    $HTTP_COOKIE_VARS["cookiename"];
    Now you get teh cookie named cookiename.
    have you use setcookie() to set the cookie at first?
    show the line your using to set the cookie.


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •