Hi,
I'm having trouble reading session data on my ajax request handler php file.
Basically this is the idea:
Index.php -- user is here, logged in.. $_SESSION['userid'] contains the user's unique ID.
On index.php a user can submit an ajax request.. the ajax request then calls ajaxhandler.php
ajaxhandler.php cannot read any session data. I have initialized the session via session_start() etc.. with no avail .
I did notice however, that if I did the following $_SESSION['test'] = "foo";
that test variable is readable back in index.php when refreshed. Now I'm really stumped as to why i cannot read session data but I can write session data.
Is it because when an ajax request is made its considered a NEW session? If so, how can I go about this issue?
thanks