automatic logout, modify database

Discussion in 'PHP' started by tirso, Feb 12, 2009.

  1. #1
    hi to all

    Here is the scenario,

    I was calculated my field into "login" after the user was loggedin, and once they hit the button logout field became "logout". My problem now is if the user does not hit the logout button but instead exit the browser my field doest not calculated into logout. How can I achieve this.

    thanks in advance

    Tirso
     
    tirso, Feb 12, 2009 IP
  2. tihan

    tihan Active Member

    Messages:
    64
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    93
    #2
    Maybe OnExit javascript code and an ajax call can help.
     
    tihan, Feb 12, 2009 IP
  3. born2hack

    born2hack Banned

    Messages:
    294
    Likes Received:
    4
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Maybe using sessions will help....call the session off if the user does not come to site for 5-10mins.
     
    born2hack, Feb 13, 2009 IP