Click to See Complete Forum and Search --> : session not global for subdomain


imranlink
07-22-2004, 10:15 AM
Hi,

I am getting problem in PHP SESSION management. Let me to explain the problem.I have a PHP Web Server (Win 2000, IIS) and having more than 10 php web sites configured on it. If i use the URL

http://www.mysite_1.com
http://mysite_1.com

with and without 'WWW', PHP create two different session_id() instead of one unqiue and i lost the data during client navigate from one page to another.

I do not want to use the session_set_cookie_params (0,'/','.mysite_1.com') because i have to change in many PHP pages and web server has many php sites using session.

If i use the PHP.ini to set the "session.cookie_domain" then again this will be for one domain not for all the domains configured on the server.

Can u please solve my problem that how can i overcome this PHP SESSION ID global for subdomains of a single domain for all the sites running on the PHP web Server?


Regards,
Imran Khalid
PHP Developer
http://imrankhalid.5u.com