session_id()的施用

WBOY
Release: 2016-06-13 13:21:51
Original
890 people have browsed it

session_id()的使用

PHP code
<!--

Code highlighting produced by Actipro CodeHighlighter (freeware)
http://www.CodeHighlighter.com/

-->
<?php ob_start('ob_gzhandler');
    
    
    session_save_path('2;D:/sessionFile/sessionFile');
    @session_start();
    
    
    echo 'Your session identification number is ' . session_id("967d992a949114ee9832f1c11c");
?>

Copy after login


为什么在session_id()中输入一个参数却不能替代当前运行的SID?与没有设置参数的效果一样。。

------解决方案--------------------
设置 sessionid 要在 session_start(); 之前
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
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template