Page 1 of 1

session.auto_start does not work without cookies.

Posted: Tue Aug 29, 2006 12:27 pm
by xsaero00
When we started developing our site the session did not need to be enabled on every page. Now after a while it is being used on almost every page, so I want to use session.auto_start instead of starting session every time explicitly.
We want to accomodate people who use cookies and those who don't. The session.auto_start works fine with cookies but once you start blocking cookies it stops working. The urls on the page do not get rewritten to include session ids. The directive session.use_only_cookies is set to 0. When I dont use session.auto_start everything works and urls do get rewritten when cookies are disabled.

I serched net for this problem and found nothing. Please help. :(

Posted: Tue Aug 29, 2006 8:38 pm
by Ambush Commander
Try setting session.use_trans_sid to 1.

However, I recommend rethinking how your application is structured and using a common include file to start the session.

Posted: Wed Aug 30, 2006 10:30 am
by xsaero00
We are using a common include that starts the session. But because this include does more that just start session it is ommited on some sceleton pages which also use session. I thought instead of refactoring I could eliminate session start code from everywhere. I'll try using session.use_trans_sid.

Posted: Wed Aug 30, 2006 1:21 pm
by Ambush Commander
You may want to do research on "Front Controller"