Předmět Autor Datum
V konfiguračním souboru: php.ini Někde tady: ; Define the probability that the 'garbage collection…
Flash_Gordon 28.05.2009 15:28
Flash_Gordon
RTFM! :-) http://www.php.net/manual/en/function.session-cach e-expire.php nebo taky s pomocí sessio…
marekdrtic 28.05.2009 15:29
marekdrtic
Platnost session sa myslim ze da aj menit: ini_set('session.gc_maxlifetime', 3600); // 1 hodina a… poslední
Intex 28.05.2009 17:44
Intex

V konfiguračním souboru: php.ini

Někde tady:

; Define the probability that the 'garbage collection' process is started
; on every session initialization.
; The probability is calculated by using gc_probability/gc_divisor,
; e.g. 1/100 means there is a 1% chance that the GC process starts
; on each request.

; This is disabled in the Debian packages, due to the strict permissions
; on /var/lib/php4. Instead of setting this here, see the cronjob at
; /etc/cron.d/php4, which uses the session.gc_maxlifetime setting below
;session.gc_probability = 0
session.gc_divisor = 100

; After this number of seconds, stored data will be seen as 'garbage' and
; cleaned up by the garbage collection process.
session.gc_maxlifetime = 1440

Platnost session sa myslim ze da aj menit:

ini_set('session.gc_maxlifetime', 3600); // 1 hodina

a ziskat cez:

ini_get('session.gc_maxlifetime');

ehm: neda sa ziskat aj cez funkciu:

session_cache_expire()

a nastavit tiez cez to:

session_cache_expire(30) // 30 minut

To som si len vygooglil... neskusal som...

Zpět do poradny Odpovědět na původní otázku Nahoru