Please suggest me solution to go logout page on inactivity just like bank pages will do. After session timeout, app has to display login page to login to the application. I am using Spring acegi security. Your help is greatly appreciated. Thank you for your time.
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试):
问题:
回答1:
One possibility is, you could place a javascript (or Meta refresh) in your web page, which makes a request to the server after the timeout period. This will automagically redirect to the login page.
回答2:
you have to just put this in your jsp page "head" tag
<meta http-equiv="refresh" content="${pageContext.session.maxInactiveInterval};url=login">
In above url you have to set your login controller path. After session expired your page will be redirected to the url specified by you.