php - prevent back button after logout page -


I have php logout page when the user clicks on the logout link, then view this page and redirect to the index page. But when I click on the backup button I see a preਿਵise page with user data. Of course, when I refresh the page, I do not see the preਿਵise page and the data. After click logout, I checked the second code (drupal) and click on the back button, I do not see the previs page and see the login page. Where is my problem, how did it fix?

LOGOUT Page:

  if (isset ($ _GET ['req']) and $ _GET ['req'] == 'logout') {session_start (); Session_destroy (); Header ("location: index.php"); Go out(); }   

thanks

The code is right No need to stop by clicking on the button. If you really think this is important, then you can save a few more cookies or logout.php and check with the main page AJX whether this cookie is set or not. And if you can reload the page with JS (and of course the cookie is not set) but in reality there are no safe methods.

Comments

Popular posts from this blog

ios - Adding an SKSpriteNode to SKScene from a child SKSpriteNode -

Matlab transpose a table vector -

c# - Textbox not clickable but editable -