On Thu, May 4, 2006 7:37 am, Merlin wrote:
> I am operating 3 sites where I would like to be able to login cross
> site. Means
> with one login have a valid session on all 3 domain.
>
> Currently I do set the cookie like this:
> setcookie($cookiename,$sessid,0,'/','.'.$domain[name],0);
>
> That makes is available for all subdomains. Is there a possiblity to
> make it
> available for all domains like example: .domainname.

You can't set/read cookies for other TLDs...

That would be a very giant security hole.

You'll have to find some other way to transfer authentication
cross-site, very carefully, to avoid exposing your application.

Plus, your $domain[name] is an E_NOTICE you are ignoring.

Assuming you did not do:    define('name', ...);

Change php.ini to E_ALL and you'll write better code. :-)

-- 
Like Music?
http://l-i-e.com/artists.htm

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to