Home > php教程 > php手册 > session的生命周期是多长

session的生命周期是多长

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
Release: 2016-06-13 11:21:07
Original
1434 people have browsed it


session 的生命周期是多长
1 浏览器结束时其生命周期也同时结束,但是档案仍然存在于 /tmp/(sess_???)
2 下次重新开浏览器时会重新分配 sessionID,如果你使用 session_id() 把以前的 ID 带回来,则会去读取残存在 /tmp 处的 sess_???, 取回你之前所有已经设定的参数
3 可以在 php.ini 里修改 session 档案残存的时间
session.gc_maxlifetime = 1440 ; after this number of seconds, stored
; data will be seen as 'garbage' and
; cleaned up by the gc process
默认是 1440 秒,24分钟

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Latest Issues
Session
From 1970-01-01 08:00:00
0
0
0
session
From 1970-01-01 08:00:00
0
0
0
session login information
From 1970-01-01 08:00:00
0
0
0
Popular Recommendations
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template