I'm in the process of migrating my application from Kohana 3.1 to 3.3. The main reason for the migration is the additional support for MySQLli driver.
I have debugged the code extensively and I'm not able to figure out why after the redirect statement, the new page is properly redirected but when the code is triggered again the $SESSION global is deleted.
I'm using native session driver (written to the file system). I'm calling the redirects within my controller.
I have tried:
this->redirect ('controller/action') ; -- no good
HTTP:redirect ('controller/action') ; - no good
Native PHP call
header (Location: 'controller/action'); - no good
In all the scenarios above, the redirect works and I can see the the session properly written in the session directory. But when I debug this in 3.1 , after the redirect the $SESSION variable is still active, allowing for validating the existing session after the redirect while in 3.3 the $SESSION object disappears. Some forums said that this could be because the $SESSION object is unset but I'm not manipulating this at all, if this happens is withing the core classes.
Can anyone involved in the development of the session module could help me find out what is wrong. I have to think is how the new version is managing sessions, since I'm running both apps under the same apache and php server and one works and the other doesn't which let me believe that the issue is within how the framework is now handling redirects as HTTP errors. Maybe the trhow catch has this effect on the global session.
Any help will be greatly appreciated.