Re: Testing if cookies are enabled

From: Date: Mon, 21 Jun 2004 11:10:32 +0000
Subject: Re: Testing if cookies are enabled
References: 1 2  Groups: php.general 
Request: Send a blank email to php-general+get-188736@lists.php.net to get a copy of this message
Hi Aidan,
Think about it. Step 1) Analyse the problem. a) Set a cookie. b) Test if the cookie has been set. c) Display data from cookie Step 2) Read the fucking manual a) http://php.net/setcookie b) http://php.net/setcookie c) http://php.net/setcookie
thanks for your reply, I think you missunderstood, please read more carefully. I know how to set and read a cookie, but as I wrote I wasn't able to set and text a cookie ON THE SAME PAGE. The manual says: http://php.net/setcookie "Once the cookies have been set, they can be accessed ON THE NEXT PAGE." But I have seen pages on which it seems they set und check if the cookie has been set ON THE SAME PAGE. So I want to know how they do that (perhaps with a 302-header or something like that?). Martin Aidan Lister schrieb:
If you can't work it out, and have actually done some reading, feel free to ask for some more help. "Martin Schneider" <cangoou@yahoo.de> wrote in message news:20040621085845.29515.qmail@pb1.pair.com...
Hello! I saw this on some pages and want to do the same: - On one page the user can login. Before that no cookie is set! - On the next page they set the cookie and show either the user data or a warning that the user has disabled cookies and should enable them. I wasn't able to set and text a cookie on the same page! How is it done? Martin


« previous php.general (#188736) next »