Hi,
On Wed, Mar 12, 2014 at 5:09 PM, Bruce Lombardi <brlom...@gmail.com> wrote: > Hi, > > > > I have a requirement that says that, for security purposes, when a session > times out, the application must go to a different page so that any data > displayed is hidden and that the user must be informed that the session > has > timed out. In the init method of my Application class, which subclasses > AuthenticatedApplication, I have the following line. > > > > getApplicationSettings().setPageExpiredErrorPage(SessionTimeoutPage.class); > > > > So now, after the session expires, if the user clicks on anything it goes > to > the SessionTimeoutPage. This is not the behavior I need, so I've done some > searching and found some suggestions on using AjaxTimerBehavior to warn a > user that a session is about to expire, but nothing that says exactly how > to > detect an expired session. Also, some people have hinted that Ajax could > actually keep the session alive so I'm a little confused about that. > This is correct. Any request to the server will touch the session and thus will keep it alive. > > > > Can someone please clarify this and at least point me in the right > direction > for fulfilling my requirements? > Your best bet is to use JavaScript counter that will count down do document.location.href="anotherUrl"; when the counter reaches 0. You will have to reinit the counter with every ajax request - this is easy. > > > > Thanks, > > Bruce > >