session过期的问题

WBOY
Release: 2016-06-06 20:46:24
Original
1109 people have browsed it

session问题,就是我session的过期时间4个小时, 设置cookie只要浏览器不关闭就能发送session_id, 现在的问题是我登录后什么也做(比如过半个小时),然后在操作的时候会让我重新登录

php设置
session.cookie_lifetime = 0
session.gc_maxlifetime = 7200

回复内容:

session问题,就是我session的过期时间4个小时, 设置cookie只要浏览器不关闭就能发送session_id, 现在的问题是我登录后什么也做(比如过半个小时),然后在操作的时候会让我重新登录

php设置
session.cookie_lifetime = 0
session.gc_maxlifetime = 7200

session.use_cookies是否为1
试试用session_save_path()函数,设定这个session的专用目录

Related labels:
php
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
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!