在ASP.NET中会话出问题 [英] Session out Problem in ASP.NET

查看:55
本文介绍了在ASP.NET中会话出问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我正在网站上.
成功登录后,我正在为会话变量设置一些值
说:

Hi,

I am working on website.
After successful login, i am seting some value to session variable
say:

Session["Abc"]="myValue";



登录后,主页上会有一些链接.
如果我在新窗口中从此链接打开新页面,则效果很好.
但是,如果我关闭了这个新窗口,然后尝试打开一个链接..,砰..
会话过期..

请帮忙吗?

[框架:3.5
浏览器:IE8
IIS:7]



after login, there are some links on the main page.
If i open the new page from this link in new window, it works fine.
But if I close this new window and then try to open a link.., Bang..
Session Expires..

Please help??

[Framework: 3.5
Browser: IE8
IIS: 7]

推荐答案



问题解决了!
我刚刚在标签System.Web下的以下代码行中,在web.config中设置了超时:

Hi,

problem is solved!!
I have just set the Timeout in web.config, from following line of code under the tag System.Web:

<sessionstate mode="StateServer" statenetworktimeout="30" regenerateexpiredsessionid="true" cookieless="false" timeout="30" />


^ ]


这篇关于在ASP.NET中会话出问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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