正如我在Laravel 4.1应用程序的帖子中提到的,我有"记住我"选项。
当我在chrome中连接并选中"记住我"时,关闭浏览器并打开它,它就可以工作了,即使我没有选中它!
但有了Firefox,它可以完美地工作。当我选中"记住我"时,关闭然后打开我仍然连接的浏览器。
当我没有检查并连接时,关闭然后打开浏览器,它会将我返回到带有错误消息的登录表单。
我不明白为什么它在铬中不起作用。
else if (Auth::attempt($credentials, $remember)) {
return Redirect::intended('/');
}
这是因为,关闭浏览器后,Chrome
可能仍在后台运行。尝试禁用Continue running background apps when Google Chrome is closed
功能,请按照以下步骤操作:
- 打开
chrome://settings
- 单击
Show advanced settings
- 转至系统部分(向下)并禁用
Continue running background apps when Google Chrome is closed
。这将强制Chrome
浏览器完全关闭,然后它也将删除会话cookie
这是一个使用Chrome
的common
问题,我以前也遇到过,并以这种方式解决了它。