4
//config.php
'session' => [
'id' => '',
'var_session_id' => '', // SESSION_ID的提交变量,解决flash上传跨域
'prefix' => 'think',
'type' => '',
'auto_start' => true,
],
//index.php
print_r($_SESSION);
$to = I("session.user", "guests");
相反,如果在上面两句之前执行一次session("");下面的就好用.