I'm using php version 4.2.3 and while writing a small script that uses sessions I've come across a problem. session_register isn't working. It returns true, but on subsequent pages a call to print_r($_SESSION) prints an empty array. I've used sessions before but that was with version 4.2.0 has anything changed that I don't know of? Has my php.ini file need revising?
TIA
just checking:
are you calling a session_start() prior to trying to read the variable? it needs to be called on every page you are using. easiest way to do it is to just write it as in include in a file and call it there, along with whatever authentication you are checking
yeah, I'm using session_start(). It's wierd, I've never had a prob before. oh well, maybe I'll try to downgrade to 4.2.2 and see if that fixes it. If not, back to the drawing board.