php - Prevent Back Login After Logout by hitting the Back button on Browser in L5?
My problem is I want to do when I already logout, If I click back button on browser it never back admin home page.
Now when I click back button It show admin secret pages, But when I refresh the page then It back to login page.
I solved it write the code in filter.php on Laravel 4.2
App::after(function($request, $response)
{
$response->headers->set('Cache-Control','nocache, no-store, max-age=0, must-revalidate');
$response->headers->set('Pragma','no-cache');
$response->headers->set('Expires','Fri, 01 Jan 1990 00:00:00 GMT');
});
But Now how can I do Prevent Back Login After Logout by hitting the Back button on Browser in L5?
Answer
Solution:
Keep this line in top of the login page.That will clear cache and prevent back page(pabel)
Answer
Solution:
that work for me:
Put this javascript code at the end of your login page, with this you can not go back and then once outside the system can not reach the previous pages
Answer
Solution: