[thelist] Why cookies does not sets

Shashank Tripathi sub at shanx.com
Wed Feb 13 23:12:00 CST 2002


Hi Laliyuswa,

Sometimes setcookie() behaves strangely in IE5 versions. Try this instead:

    $time = mktime() + 86400;
    $date = date("l, d-M-y H:i:s", ($time));
    header("Set-Cookie: cookiename=$value; expires=$date GMT");


In this example, the cookie will expire in a day (86,400 seconds).

Hope this helps,
Shanx






More information about the thelist mailing list