Announcement

Collapse
No announcement yet.

Managing Sessions

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Managing Sessions

    Hi can some please help guide me here.

    I have created a login screen for various users which takes them to a menu screen.
    What I want to do is the following:
    1) When a user logs in I would like to be able to identify when their socket session has timed out, this way taking them back to the log in screen.
    2) When the user clicks on the logout item in the menu, it ends that session.

    Please again can someone guide through each of the above.

    Thanks in advance

    Larry

  • #2
    Originally posted by Larryh1115 View Post
    Hi can some please help guide me here.

    I have created a login screen for various users which takes them to a menu screen.
    What I want to do is the following:
    1) When a user logs in I would like to be able to identify when their socket session has timed out, this way taking them back to the log in screen.
    2) When the user clicks on the logout item in the menu, it ends that session.

    Please again can someone guide through each of the above.

    Thanks in advance

    Larry
    ad1. You cannot do this. You can control session time out, but that based upon time, not sockets. Google for scriptcase session time out on youtube and you'll find an explaining video regarding this matter.
    ad2. You can apply a menu item and set target to leave. It will close your session. Fill the correct link to be able to jump to the login screen.
    Albert Drent
    aducom software netherlands
    scriptcase partner, reseller, support and (turn-key) development
    www.scriptcase.eu / www.scriptcase.nl

    Comment


    • #3
      Thanks Albert
      However, does the above NOT retain the connection until the user does something, and only then does it release the connection. If this is so, perfect for security, but is there a way to run this type of process such that it is constantly monitoring for that users activity using time? Thus if no activity it kills that session. This way freeing up a node in mySQL

      Comment


      • #4
        What is no activity? Is that the user doesnt send some ajax info the the webserver? Well just set the php session timeout downwards.
        You could always check the $_SESSION variable tho.

        Comment


        • #5
          Originally posted by rr View Post
          What is no activity? Is that the user doesnt send some ajax info the the webserver? Well just set the php session timeout downwards.
          You could always check the $_SESSION variable tho.
          I was just about to ask a question on this matter, so here may well be appropriate.

          The YouTube video shows you how to set up and check for a "timeout", but it has one major flaw, and I was wondering what other people do to make it work.

          At present (based on the video tutorial) clicking on the menu invokes the check on time elapsed and it works fine, but this method does leave the current application open AND editable which I consider a vulnerability. Is there a way to set up a timer of some form so that when you open an application, and the timer checks the idle time and then gives an alert before redirecting. So it is similar to the SC example, but would not rely on a menu item being clicked before issuing the alert.

          Thanks heaps - and remember I also am a little new to javascript etc, so be kind in your replies

          Tony

          Comment

          Working...
          X