Results 1 to 5 of 5

Thread: session timeout

  1. #1
    nmbalaji is offline Member
    Join Date
    Dec 2008
    Posts
    2
    Rep Power
    0

    Default session timeout

    i had set 1 minute time for my homepage. After 1 min it move back to the login page without any alert. So i need to throw alert mesage after 1 minute as "Your session expired. Please login again". How can i do that?

  2. #2
    zoomix is offline Member
    Join Date
    Oct 2008
    Location
    Sweden, Gothenburg
    Posts
    21
    Rep Power
    0

    Default

    To the best of my knowledge, there's no super-clever way of doing this. If the session has expired, it has expired. However. You can forward the user to a page that notifies them of the session expiring.


    Timeline would look something like this:
    00:00 /login.jsp //User logs in
    00:01 /doStuff.jsp //User does what the user does.
    00:10 /doStuff.jsp //User does what the user does.
    00:16 /doStuff.jsp //User does what the user does.
    //a minute passes
    01:17 /loggedOut.jsp //User is forwared to a page that explains that the session has expired and that use will have to log in again to be able to doStuff

  3. #3
    uncommon is offline Member
    Join Date
    Dec 2008
    Posts
    30
    Rep Power
    0

    Default

    Is there anything preventing you from invoking a javascript alert on the login page if they were redirected.

  4. #4
    zoomix is offline Member
    Join Date
    Oct 2008
    Location
    Sweden, Gothenburg
    Posts
    21
    Rep Power
    0

    Default

    Quote Originally Posted by uncommon View Post
    Is there anything preventing you from invoking a javascript alert on the login page if they were redirected.
    How can you tell if you were redirected to login.jsp or if you just entered login.jsp?

  5. #5
    uncommon is offline Member
    Join Date
    Dec 2008
    Posts
    30
    Rep Power
    0

    Default

    You could redirect them to an alternate login page other then login.jsp. The code would be the same aside from the alert.

Similar Threads

  1. Implement a timeout
    By pjmorce in forum Advanced Java
    Replies: 5
    Last Post: 04-27-2010, 02:36 AM
  2. Connection timeout exception
    By wickedrahul9 in forum Advanced Java
    Replies: 2
    Last Post: 11-13-2008, 08:32 AM
  3. Session Timeout alert message
    By hemendra.rathore in forum Advanced Java
    Replies: 1
    Last Post: 11-03-2008, 07:03 AM
  4. RAD - Error getting connection: Timeout.
    By ShoeNinja in forum Other IDEs
    Replies: 0
    Last Post: 09-09-2008, 05:25 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •