NewUser
Posts: 6
|
Posted: 06/10/2014, 4:00 AM |
|
Hi,
I have upgraded to codecharge 5.1 version. When User clicks Logout, Iam clearing all the session variables. But when browser back button is clicked, the session variable values are still available.
I didnt have this problem with codecharge 5.0 version with the same code.
Also, I have added session_start() in common.php since sessions were not available after logging in.
Any help is appreciated.
Thanks
|
|
|
MichaelMcDonald
Posts: 640
|
Posted: 06/10/2014, 7:05 PM |
|
If logout takes you to the login page?
Then on your login page, may be in the page before initialize event or similar event put this:
CCSetSession("sessionvariablename","");
_________________
Central Coast, NSW, Australia.
|
|
|
MichaelMcDonald
Posts: 640
|
Posted: 06/10/2014, 7:15 PM |
|
And here's a little JS that emulates disabling the browsers back button by re-forcing forward to the last page .. it's cool because it forces users to use links or buttons....
<script type="text/javascript">
window.history.forward();
function noBack() { window.history.forward(); }
</script>
<body onpageshow="if (event.persisted) noBack();">
_________________
Central Coast, NSW, Australia.
|
|
|
NewUser
Posts: 6
|
Posted: 06/11/2014, 12:31 AM |
|
Hi,
Thanks for the reply. I tried putting session_unset() in page before initialize event of login page. But still i am getting the same issue..
Thanks
|
|
|
MichaelMcDonald
Posts: 640
|
Posted: 06/11/2014, 6:39 PM |
|
CCSetSession("sessionvariablename","");
declares it as a null.
_________________
Central Coast, NSW, Australia.
|
|
|
|