Free Android CakePHP GMaps Articles by Bali Web Design

February 13, 2012

How to enable and disable PHPSESSID

Filed under: php-tips-basic — admin @ 10:13 pm

For some case where the visitor cannot save cookie, we need to put it on the url. This is happen on some browser also that cannot save cookie, like i-mode in japan. It will be a big task to add PHPSESSID to all pages URL, so we can enable PHPSESSID using php script setting.


ini_set('session.use_cookies', 0);
ini_set('session.use_only_cookies', 0);
ini_set('session.use_trans_sid', 1);
ini_set('session.name', 'PHPSESSID');
ini_set('url_rewriter.tags', 'a=href,area=href,frame=src,input=src,form=,fieldset=');

(more…)