Hello List,

I'm trying to figure the best method to see if cookies are enabled before proceeding.

So what I've done is this:

        METHOD 1:
                see if a certain cookie exists and if not set it
                then later on teste for the cookie again 
                it will not be set because the headers just set it
                so while the browser now has one it is not returned 
                to the same script that set it so this way is no go

        METHOD 2:
                if(param('cookie_should_be_set')) {
                        test for cookie and if not defined die you need cookies
                } else { 
                        see if a certain cookie exists and if not set it 
                        and print a Location header to self_url with    
                        cookie_should_be_set=1 appended
                }

Method 2 works but I'm looking for the best way to test it with each request, in case 
they turn cookies off and then click a link or something. And doing a Location: 
$self_url everytime isn't desireable and setting one cookie and testing it over and 
over sounds good but sometimes browsers will still return a cookie even thought 
cookies are disabled/blocked/off so that will show it has a cookie but wonb't tell me 
if it can successfully set others.

The best I can come up with so far is METHOD 2 with the cookie life set to a few 
minutes so it only has to do the Location: ... Bit once evr few minutes instead of 
every single request.

Any other ideas/modules I'm missing?

Tia

Dan

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to