Ask the community if you have any question about PHP,
MySQL, Apache and Linux for quick answers!!!

PHP sessions across subdomains

If you are facing problems sharing sessions across subdomains, use the following code before session_start().

ini_set ( 'session.cookie_domain', '.mysite.com' );

Replace mysite.com with your domain name.

Still need help? Ask us

  • No related posts
  • Leave a Comment