SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Guru
    Join Date
    Sep 2004
    Location
    Provo, UT
    Posts
    858
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)

    How to extend the default time for sessions

    I maintain few different domains in one account at my ISP. How do I go about making a change to the timeout time for a session on one domain, but not all of the others?

    Thank you.
    Convert your dollars into silver coins. www.convert2silver.com

  2. #2
    SitePoint Wizard
    Join Date
    Feb 2009
    Posts
    1,006
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I'm not sure of this. That seems to be more like a server admin question then a programming question.

    If you have a local php.ini file for each host then try editing:
    session.gc_maxlifetime = 14400

    If you don't have a local php.ini file, then try something like this on your htaccess file:

    php_value session.gc_maxlifetime 14400


    Does this worked?

  3. #3
    Utopia, Inc. silver trophy
    ScallioXTX's Avatar
    Join Date
    Aug 2008
    Location
    The Netherlands
    Posts
    9,080
    Mentioned
    153 Post(s)
    Tagged
    2 Thread(s)
    oikram is right, but make sure you read the first note on here and set a session.save_path for the domain as well.
    Rémon - Hosting Advisor

    SitePoint forums will switch to Discourse soon! Make sure you're ready for it!

    Minimal Bookmarks Tree
    My Google Chrome extension: browsing bookmarks made easy


Bookmarks

Posting Permissions

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