大佬教程收集整理的这篇文章主要介绍了php-在Kohana中登录时出现错误消息,大佬教程大佬觉得挺不错的,现在分享给大家,也给大家做个参考。
我使用此行登录:
$success = Auth::instance()->login($_POST['login_user'], $_POST['login_password'], $remember);
我得到了这个错误信息:
Session_Exception [ 1 ]: Error reading session data. ~ SYSPATH/classes/kohana/session.PHP [ 326 ]
create table `sessions` (
`session_id` varchar(24) NOT NULL,
`last_active` int(10) unsigned DEFAULT NULL,
`contents` text,
PRIMARY KEY (`session_id`),
KEY `sessions_fk1` (`last_active`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
<?PHP defined('SYSPATH') or die('No direct script access.');
return array(
'database' => array(
/**
* Database setTings for session storage.
*
* String group configuation group name
* String table session table name
* Integer gc number of requests before gc is invoked
* columns array custom column names
*/
'group' => 'default',
'table' => 'sessions',
'gc' => 500,
'columns' => array(
/**
* session_id: session identifier
* last_active: timestamp of the last activity
* contents: serialized session data
*/
'session_id' => 'session_id',
'last_active' => 'last_active',
'contents' => 'contents'
),
),
);
?>
这可能是什么问题?
谢谢!
解决方法:
取决于您正在运行的版本,但这是由于在读取会话数据时未序列化而引发异常时引起的.您可以在此处查看有关此错误的报告:Session read errors not properly ignored.解决方案是如果尚未升级到最新版本.
您需要查看的其他内容是会话数据.您必须查看为什么数据损坏并且无法正确读取的原因.这可能是从__sleep中的代码生成的错误.
以上是大佬教程为你收集整理的php-在Kohana中登录时出现错误消息全部内容,希望文章能够帮你解决php-在Kohana中登录时出现错误消息所遇到的程序开发问题。
如果觉得大佬教程网站内容还不错,欢迎将大佬教程推荐给程序员好友。
本图文内容来源于网友网络收集整理提供,作为学习参考使用,版权属于原作者。
如您有任何意见或建议可联系处理。小编QQ:384754419,请注明来意。