How to set the SESSION EXPIRE TIME ?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Angelos

    How to set the SESSION EXPIRE TIME ?

    Anyone knows how to expire a session after a specific time for a specific
    SITE and not globally ?

    I want if the user forgets his browser window open to automatically expire
    the session after 20 mins more or less....


  • Mike Willbanks

    #2
    Re: How to set the SESSION EXPIRE TIME ?

    Angelos wrote:[color=blue]
    > Anyone knows how to expire a session after a specific time for a specific
    > SITE and not globally ?
    >
    > I want if the user forgets his browser window open to automatically expire
    > the session after 20 mins more or less....
    >
    >[/color]
    www.php.net/session explains something you could use for ini_set or even
    a .htaccess file for your site.

    Mike

    Comment

    • Juha Suni

      #3
      Re: How to set the SESSION EXPIRE TIME ?

      Angelos wrote:[color=blue]
      > Anyone knows how to expire a session after a specific time for a
      > specific SITE and not globally ?[/color]

      In addition to earlier comments by others, you should also check my earlier
      post on thelist about the subject, and especially PHP's builtin garbage
      collection:

      [color=blue]
      >
      > I want if the user forgets his browser window open to automatically
      > expire the session after 20 mins more or less....[/color]

      Actually the default value is 24 minutes.

      --
      Suni


      Comment

      Working...