Jump to content

Recommended Posts

Hi
This script always throws the message "Cookies are disabled".


[code]

<?php ob_start('ob_gzhandler');

if (!isset($_COOKIE['RESULTS']))
{
session_name('RESULTS);
session_set_cookie_params(3600, "/results", "", 0);
session_start();
ob_flush();
if (!isset($_COOKIE['RESULTS'])) {echo "Cookies are disabled";}
}
else
{
echo $COOKIE['RESULTS'];
}
?>

[/code]

Thanks

Link to comment
https://forums.phpfreaks.com/topic/10846-plz-debug-this/
Share on other sites

HI

Actually, I am modifying the php sessin id name.
I ve changed the name from PHPSESSID to RESULTS
So the cookie RESULTS would contain the session id
generated by php. I dont wanna change the value of the
cookie. Moreover When i check the cookie RESULTS,
it contains the the session_id. So it is already set, right

Thanks
Link to comment
https://forums.phpfreaks.com/topic/10846-plz-debug-this/#findComment-40521
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.