I have a PHP login which sets 2 cookies once someone login. The problem is that if you login from http://www.example.com and you go to http://example.com, you will find yourself not logged in. I think that is because the browser only send the cookies to the first syntax.
It is only one domain, the difference is the www.
before the domain name, so how to set cookies to the whole domain whatever there is www.
or not?
<?php setcookie('username',$username,time()+3600); ?>