Question is simple. I do not want to use session id because I heard that crawlers test your pages without cookies and then we get an ugly link (is this true?) So, my decision is just not letting users use site if cookies are disabled (gmail does this) My idea is to redirect with header at the beginning of index.php to another php, there set cookie, return to index.php and check there for cookie. But this will create eternal loop Any ideas?
Why not just something like this Set a cookie and check it on same page itself ?? setcookie("user", "Test Cookie", time()+3600); if (isset($_COOKIE["user"])) Proceed else exit and do whatever u want it too
when you use setcookie, you can't just proceed, you need to refresh a page didn't have time to think a lot, but it could be done with more than 2 pages involed since a page has to be reloaded or redirected to check for a cookie i've just put warning with some onclick javascript window, like "you must enable cookies" near login area