1
I'm trying out XOOPS 2.0.16 and writing some homemade custom modules for it. Now I have a really strange problem: sometimes the PHPSESSID is stored into a cookie, and sometimes in the get variable (which means I can't do anything, at least not admin things). When I say sometimes, I really mean sometimes. I tried tracking down where the problem is, but sometimes even with the same code and the same database, it drives me crazy. I did quite a bit of searching, but because I don't know how to define my search exactly, I couldn't find it, and most topics are about other problems.
It can't be that headers are already sent, because then the same code would fail always, wouldn't it? (and it does not give any errors at all)
Now I have this:
online webhost, all browsers: $_GET session
localhost, firefox: $_GET session
localhost, opera: $_COOKIE session (and I'm not going to try to log out yet, because I think it will switch to $_GET too)
And this is just the current situation, it can easily be the other way around.
I tried adding session_start() and some more of the code on top of index.php, but it didn't work.
Local: Apache/1.3.34, php 4.x-something, on the webhost there's Apache/2.0.51, I think also php 4.
It can't be that I'm the only one with this problem? Is there a way to start my session on top of everything and make use of it later?