遇到一个问题,发现网站中的所有ajax在某个服务器中的session总是无效,后来同事查了资料,原来PHP的配置文件中有个选项:@H_301_1@
@H_301_1@
; Whether or not to add the httpOnly flag to the cookie,which makes it inaccessible to browser scripting languages such as JavaScript.
session.cookie_httponly =
@H_301_1@
@H_301_1@
当设置了这个值为1后,所有的ajax请求的session将无法识别。@H_301_1@
@H_301_1@
[作者邮箱]zengjiansheng1@126.com@H_301_1@
[作者QQ]190678908@H_301_1@