Turned off sessions but CMSSESSID still appears in News module output

For questions and problems with the CMS core. This board is NOT for any 3rd party modules, addons, PHP scripts or anything NOT distributed with the CMS made simple package itself.
matt

Turned off sessions but CMSSESSID still appears in News module output

Post by matt »

All,

I don't need session and I'd like to turn off appending CMSSESID to each url. I added:

Code: Select all

ini_set('session.use_trans_sid', false);
to include.php just before session_start() and it seems to have solved the problem everywhere, except links that are displayed from News module. Even those links I add manually to a news item are appended. Does the News module overwrite the session.use_trans_sid somehow?

I had the same problem with "print" plugin, but I stopped using it and it solved the problem :).

Matt.
Ted
Power Poster
Power Poster
Posts: 3329
Joined: Fri Jun 11, 2004 6:58 pm

Re: Turned off sessions but CMSSESSID still appears in News module output

Post by Ted »

It's not overriding it.  I thought I read somewhere that use_trans_sid can't be overridden with ini_set.  You might have better luck putting:

Code: Select all

php_flag session.use_trans_sid off
in an .htaccess (assuming you have access to do such a thing).
matt

Re: Turned off sessions but CMSSESSID still appears in News module output

Post by matt »

I can't do that, because setting any php_flag in my .htaccess causes internal server error and renders my site unusable (I've no idea why that happens).

And the strange thing about this is that the CMSSESSID only appears when I open my page in a new browser instance (not new window). If I refresh the page, or navigate to it from any other page, the CMSSESSID is not there anymore.

Matt.
Alex_Leipzig

Re: Turned off sessions but CMSSESSID still appears in News module output

Post by Alex_Leipzig »

I have a similar problem with the UserID module (already described here).
After entering my login data and pushing the ok button, I am "forwarded" to my error page. In the adress line, I see the url of the login page plus cmssess... When I then go to the requested (protected) page, everything's fine - just until I log out. Then, the same thing happens again. Was that understandable?
matt

Re: Turned off sessions but CMSSESSID still appears in News module output

Post by matt »

I think I found a solution int the comments here: http://us3.php.net/session

I added:

Code: Select all

@ini_set('url_rewriter.tags', '');
@ini_set('session.use_trans_sid', 0);
to my include.php and commented the next few lines that set session name and start the session. It seems to work.

Matt.
Ted
Power Poster
Power Poster
Posts: 3329
Joined: Fri Jun 11, 2004 6:58 pm

Re: Turned off sessions but CMSSESSID still appears in News module output

Post by Ted »

...and the admin is still working?
matt

Re: Turned off sessions but CMSSESSID still appears in News module output

Post by matt »

It's working... but maybe something is still cached?

I don't know, but I'm editing some templates right now and everything seems to be ok.
Ted
Power Poster
Power Poster
Posts: 3329
Joined: Fri Jun 11, 2004 6:58 pm

Re: Turned off sessions but CMSSESSID still appears in News module output

Post by Ted »

Very strange.  Oh well, at least it's working.  :)

I guess the admin would work without sessions enabled, but it means that it's hitting the database everytime for all of the user info.  It's not a big deal, as it's only a query or two...

Maybe it would be worth putting an option in to disable sessions in config.php?
Alex_Leipzig

Re: Turned off sessions but CMSSESSID still appears in News module output

Post by Alex_Leipzig »

wishy wrote: Maybe it would be worth putting an option in to disable sessions in config.php?
Guess it would!
levent

Re: Turned off sessions but CMSSESSID still appears in News module output

Post by levent »

I have a similar problem with the UserID module (already described here).

After entering my login data and pushing the ok button, I am "forwarded" to my error page. In the adress line, I see the url of the login page plus cmssess... When I then go to the requested (protected) page, everything's fine - just until I log out. Then, the same thing happens again.

?? is there no solution for it?
kishman155
Translator
Translator
Posts: 169
Joined: Sat Mar 12, 2005 12:30 pm

Re: Turned off sessions but CMSSESSID still appears in News module output

Post by kishman155 »

You could try this I am working on it now.

I Postit on wiki to have the ability to go around this problem

It's the first look

I don't like it to use UserID becouse i was to stupid to make it work.

closer hand i write something else and it's nearly ready but there are some features i like to add.

it called zugriffmodul

a small help file is included maybe i get it ready this weekend.

please try and report me some bugs.

kishman155
numer9

Re: Turned off sessions but CMSSESSID still appears in News module output

Post by numer9 »

hey,
i'm having similar problems to everybody with UserID module (bad formed address ?page=test?CMSSESSIONID=xxx) and tried to find your zugriffmodul, but i wasn't able to do so. what about it? Is it done?

regards,
kishman155
Translator
Translator
Posts: 169
Joined: Sat Mar 12, 2005 12:30 pm

Re: Turned off sessions but CMSSESSID still appears in News module output

Post by kishman155 »

I have some problems with zugriffsmodule to Implement it into CMSMS.
So I make an rebuild to be more userfriendly but I could not say when it's
ready.

mfg
kishman155
Umer

Re: Turned off sessions but CMSSESSID still appears in News module output

Post by Umer »

I'm getting this error! 
Warning: Smarty error: unable to read resource: "db:secure?CMSSESSID=ade01dd4a63ff63a2d8172db65fa8446" in /home/******/public_html/MYFOLDER/lib/smarty/Smarty.class.php on line 1088
I tryed both the solutions from wishy & matt, but had no luck!! Is there anywat I can fix this problem?? thanks!
Ted
Power Poster
Power Poster
Posts: 3329
Joined: Fri Jun 11, 2004 6:58 pm

Re: Turned off sessions but CMSSESSID still appears in News module output

Post by Ted »

What version of php do you have?  I'm guessing it's older than 4.3.2. :)
Locked

Return to “CMSMS Core”