Jump to content

Archived

This topic is now archived and is closed to further replies.

otuatail

extending a time out of a session

Recommended Posts

how do i extending a time out of a session. Does it have to be done on each web page. ?

Desmond.

Share this post


Link to post
Share on other sites
[!--quoteo(post=374817:date=May 18 2006, 12:42 AM:name=ryanlwh)--][div class=\'quotetop\']QUOTE(ryanlwh @ May 18 2006, 12:42 AM) [snapback]374817[/snapback][/div][div class=\'quotemain\'][!--quotec--]
change the php ini value session.cookie_lifetime
[/quote]

This does not help

change the php ini value session.cookie_lifetime

I have no access to the server I am a user of a web host.

ALL i have is session destroy, Unload etc.

Share this post


Link to post
Share on other sites
This is obviously a dificult one I thought someonre knew of a a way of extending a sesion timeout from
the default 20 minutes to 30 minutes in code. It can be done in ASP.

Share this post


Link to post
Share on other sites
Hello,

Use session_set_cookie_params() in a page which is included in all pages (example : header or database connections file)

hth

Share this post


Link to post
Share on other sites
PHP Manual gives example session_cache_expire For PHP 4.2.0 and above
I get an error on this undefind function. My Web remote server is 4.3.2

session_cache_expire can be used to set a time or return a time. Documentation states default 180 and this is in minutes

session_set_cookie_params(180); does not give an error. If this is working is the time 180 minute and can I get the current value as session_cache_expire claims.

Share this post


Link to post
Share on other sites
session.cookie_lifetime(180); Fatal error: Call to undefined function: cookie_lifetime() in e:\domains\d\des-otoole.co.uk\user\htdocs\index.php on line 4
session_start();

session_set_cookie_params(180); times out after 20 minutes
session_start();

session_cache_expire(180); times out after 20 minutes
session_start();

session_start();
session_cache_expire(180); times out after 20 minutes but Session remains on new browser

session_start();
session_set_cookie_params(180); times out after 20 minutes but Session remains on new browser

None of the above functions in any configuration works. The figure of 180 comes from this website session_cache_expire
and is suposed to be the default in minutes.

Share this post


Link to post
Share on other sites

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.