In my web application, after logging out, if Back button of the browser
is clicked, it takes to the previous logged in pages and allows all
operations without logging in. The layout, however, doesn’t change, but
the yield pages.
Please help me prevent that back button operation after logout. Given
below is my logout controller.
if session[:admin] || session[:user]
flash[:notice] = ‘Logged out successfully’
redirect_to :controller => ‘homes’, :action => ‘index’
flash[:error] = ‘Not logged in’
Your prompt response is appreciated.