在Kohana 3.2中错误读取会议数据 [英] ERROR READING SESSION DATA in Kohana 3.2

查看:115
本文介绍了在Kohana 3.2中错误读取会议数据的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在与Web开发框架Kohana 3.2的会话中遇到问题,这显然是一个最多可以解决的错误.它报告SESSION_EXCEPTION [1]:读取会话数据时出错. 我的Kohana应用程序不在根文件夹中,我想知道这是否与它有关.

I am having a problem with the session with the web development framework Kohana 3.2 that apparently is a bug that, at most, can be workarounded. It reports SESSION_EXCEPTION [ 1 ]: ERROR READING SESSION DATA. My Kohana application isn't in the root folder and I wonder if that has something to do with it.

我尝试了几种可能的解决方案,但没有一个起作用.以下是其中一些:

I have tryed several possible solutions but none of them have worked. Here are some of them:

1),使用一个库(Facebook SDK),单独初始化了会话,并使用$ _SESSION变量完成了会话处理.因此,有两个cookie-会话(Kohanas会话ID)和PHPSESSID. * => $ _COOKIE *中只有一个"session"和"PHPSESSID"变量.

1) using one library (Facebook SDK), session was initialized on it's own, and session handling was done using the $_SESSION variable. So there were two cookies - session (Kohanas session id) and PHPSESSID. *=> There is only one "session" and "PHPSESSID" variables in $_COOKIE*

2)在php.ini session.auto_start = 0中设置了解决方法或解决方案. =>我正在共享服务器(iPage)中工作,我很确定我无法编辑php.ini文件.

2) Workaround or solution was setting in php.ini session.auto_start = 0. => I am working in a shared server (iPage) and I am pretty sure I can't edit the php.ini file.

3)某些用户的会话文件试图保存到不存在的目录中.因此,他将session.save_path更改为有效路径,并对其进行了修复. => 如果他在谈论此php本机功能,我已经创建了一个目录并将其调用此函数作为会话文件夹进行设置.效果也不好.但是,我不确定是否正确执行了(路径"/"将是根目录,而不是kohana所在的位置,对吗?)

3) some user's session files were trying to get saved to a directory that didn't exist. So he changed the session.save_path to a valid path and that fixed it. => If he was talking about this php native function , I've created a directory and set it calling this function as the session folder. It didn't work as well. However, I got unsure if I did it correctly (the path "/" would be the root, and not where kohana is in, right?)

4)显然,此错误已报告给kohana 此处,但我无法采取行动通过阅读.

4) Apparently this bug is reported to kohana here but I wasn't able to act from reading it.

外面有人可以帮助我吗?预先感谢.

Is somebody out there able to help me? Thanks in advance.

推荐答案

在对它进行了很多研究并升级到KOHANA 3.3之后,我得出的结论是,在本地函数session_start()中调用此函数时会导致此错误. Kohana_Session_Native类别.这是由于PHP 试图将会话保存在不可用的目录中引起的.因此,我只是在php.ini中更改了此路径,一切都解决了.您也可以只在application/bootstrap.php中调用函数session_save_path('YOUR_PATH').

After researching very much about it and upgradion to KOHANA 3.3, I came to the conclusion that this error was caused when the native function session_start() was called in the Kohana_Session_Native class. It was caused because PHP was trying to save the session in an unavaiable directory. Thus, i just changed this path in php.ini and everything was solved. You may also just call the function session_save_path('YOUR_PATH') in the application/bootstrap.php.

这篇关于在Kohana 3.2中错误读取会议数据的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆