闪存消息未显示在实时服务器上,而是在本地显示
我正在调试YII2应用程序,我只是将项目复制为调试,问题是本地闪存消息正在显示,但在Live Plesk Linux服务器上,闪存消息未显示同一YII2 App。
我在后端/config/main.php会话组件中注意到未定义,这可能是问题吗?我在哪里在Linux服务器中找到会话文件,以确保是否正在生成会话。
'components' => [
'errorHandler' => [
'errorAction' => 'site/error',
],
'assetManager' => $assets,
'authManager' => [
'class' => 'yii\rbac\DbManager',
// uncomment if you want to cache RBAC items hierarchy
// 'cache' => 'cache',
],
'urlManager' => [
'rules' => [
'<controller:\w+>/<action:[a-zA-ZöäüßÖÄÜ\-]+>/<id:\d+>' => '<controller>/<action>',
'<controller:\w+>/<action:[a-zA-ZöäüßÖÄÜ\-]+>' => '<controller>/<action>',
'<controller:\w+>/<id:\d+>' => '<controller>/view',
],
],
],
在XAMP中,我可以看到在xamp/temp
文件夹中创建了会话,在Linux Server var/lib/php5/sessions
我可以看到会话正在创建,如temp 。但是在实时服务器会话中没有显示。
顺便说一句,我刚刚开始学习yii2,我的问题听起来很基本。
I am debugging a yii2 application, I simply copied project to debug, the problem is that locally flash messages are showing but on live plesk linux server, the flash messages are not showing for the same yii2 app.
I noticed in backend/config/main.php session component is not defined, could it be the issue? and where do I locate session file in linux server to make sure if session is being generated.
'components' => [
'errorHandler' => [
'errorAction' => 'site/error',
],
'assetManager' => $assets,
'authManager' => [
'class' => 'yii\rbac\DbManager',
// uncomment if you want to cache RBAC items hierarchy
// 'cache' => 'cache',
],
'urlManager' => [
'rules' => [
'<controller:\w+>/<action:[a-zA-ZöäüßÖÄÜ\-]+>/<id:\d+>' => '<controller>/<action>',
'<controller:\w+>/<action:[a-zA-ZöäüßÖÄÜ\-]+>' => '<controller>/<action>',
'<controller:\w+>/<id:\d+>' => '<controller>/view',
],
],
],
In Xamp, I can see sessions are being created in Xamp/Temp
folder, and on linux server var/lib/php5/sessions
i can see session being created as in temp. But on live server session is not showing.
btw I just started learning yii2, incase my question sounds basic.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论