Inheritance is your friend. If you need processing common to all your Action classes, extend the Struts Action class.
Ed ----- Original Message ----- From: "Baljinder Singh" <[EMAIL PROTECTED]> To: "Struts Users Mailing List" <[EMAIL PROTECTED]> Sent: Sunday, December 07, 2003 5:41 AM Subject: RE: How to detect that session has expired ? > Thomas, > > You mean to say that I should put this logic in ActionClass. But then I > would need to put it in all my Action Classes. Can't I do something similar > in JSP because then I would do it in a common JSP which is included in all > other JSPs of mine. Or is there a common solution which can take care all > Action Classes. > > Thanks, > BS > > -----Original Message----- > From: Thomas Cornet [mailto:[EMAIL PROTECTED] > Sent: Sunday, December 07, 2003 2:17 PM > To: Struts Users Mailing List > Subject: Re: How to detect that session has expired ? > > > > > When a session restarts, its context is empty, so all objects stored in > the session context have disappeared. To detect if a session has restarted, > you need first to store an object in the session context, then each time > you need to know if the session has restarted, you test its presence in the > context. If it is not there anymore, then the session has restarted. > > At 08:09 07/12/2003, you wrote: > >Hi All, > > > >How can I detect that session has expired and so throw the user out of > >system after showing him a message that "Your session has expired. Please > >login again." > > > >Thanks, > >BS > > > > > >--------------------------------------------------------------------- > >To unsubscribe, e-mail: [EMAIL PROTECTED] > >For additional commands, e-mail: [EMAIL PROTECTED] > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]