Re: Changing Session Timeout

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 4/27/07, tedd <tedd@xxxxxxxxxxxx> wrote:
At 12:26 PM -0500 4/27/07, Aaron Axelsen wrote:
>With the following set, its still timing me out.  I logged in and
>waited about 40 minutes, and it was timed out by then.  This is
>getting very confusing, what else could it be that is causing this to
>not work?
>
>session_name('myapp');
>
>$mytimeout = 180 * 60; // minutes * 60
>
>session_set_cookie_params($mytimeout);
>
>$sessdir = ini_get('session.save_path')."/myapp";
>if (!is_dir($sessdir)) { mkdir($sessdir, 0777); }
>ini_set('session.save_path', $sessdir);
>
>// New Attempt
>session_cache_limiter();
>session_cache_expire($mytimeout / 60);
>ini_set('session.gc_maxlifetime', $mytimeout);
>#ini_set('session.gc_probability',1);
>#ini_set('session.gc_divisor',1);
>
>session_start();
>

The above is not the order of your code, is it?

If so, move session_start(); to the top, namely the first line of code.

Cheers,

tedd

Uhm, ini_set would come before session_start right? when session start
is executed, then the ini value would be read right?

the order is probably the problem here..

Tijnema

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux