包含会话未在线运行的网页 [英] Webpages containing session not running online

查看:74
本文介绍了包含会话未在线运行的网页的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个网站,其管理网站包含会话。会话在Global.asax页面中进行,并添加到管理站点的母版页。它正常脱机运行。但在服务器上,当我登录管理站点并进入管理主页时,没有页面进一步打开。任何解决方案?

是否需要在Web.config文件中编写用于会话的内容。我没有在与session相关的web.config中写任何内容。

I have a website with its admin site containing session. The session is made in Global.asax page and added to master page of admin site. It's running properly offline. But at server, when I log on to admin site and come at admin home page, no page is further opening. Any solution?
Is there any need to write something in Web.config file for session. I haven't written anything in web.config related to session.

推荐答案

如果我正确理解了这个问题,问题可能与cookie域有关。在本地浏览时,管理员和其他站点的域名是相同的,即localhost,这就是会话共享的原因。
您需要更新web.config以指定父域以共享会话。但请注意,所有cookie和会话都将在两个站点之间共享。

If I understand the question correctly, the problem may be related to cookie domain. While browsing locally, your domain for admin and other site is same i.e localhost and that is why the session is shared.
You will need to update your web.config to specify the parent domain to share the Session. But be careful that all your cookies and session will be shared between the two sites.
<httpCookies domain=".parentDomain.com"/>





如果有帮助请告诉我。



Let me know if that helps.


这篇关于包含会话未在线运行的网页的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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