php - Assigning and Passing Sessions Variables Between Subdomains -
i going create site have have multiple subdomains. example:
shop.domain.com
blog.domain.com
news.domain.com
account.domain.com
i know if session variables can passed between subdomains. example $_session['variable']
accessible on of subdomains listed above.
you first have make sure store session data in way hosts can access them; if hosted on same machine fine, otherwise might want use session handler e.g. uses database, memcache, ... store session data. have make sure session id available on subdomains; can achieved setting ini.session.cookie-domain.
for more information on sessions should read appropriate chapter in fine php manual.
Comments
Post a Comment