如何设置在web.config中会话超时 [英] How to set session timeout in web.config

查看:100
本文介绍了如何设置在web.config中会话超时的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经很努力,但无法找到如何设置会话超时值进程内会话一个ASP.Net Web应用程序的解决方案。

我使用VSTS 2008 +净3.5 + C#。下面是我写的由我自己来设置超时时间为1分钟,是正确的?

我下的System.Web部分中的写的web.config

 <的sessionState超时=1模式=是InProc/>


解决方案

是这样的:

 <结构>
  <&的System.Web GT;
     <的sessionState超时=20>< /&的sessionState GT;
  < /system.web>
< /结构>

应该看到你的权利。

I have tried very hard but cannot find a solution on how to set session timeout value for in-process session for an ASP.Net web application.

I am using VSTS 2008 + .Net 3.5 + C#. Here is what I wrote by myself to set timeout to be 1 minute, is it correct?

I wrote under system.web section in the web.config

<sessionState timeout="1" mode="InProc" />

解决方案

Something like:

<configuration>
  <system.web>
     <sessionState timeout="20"></sessionState>
  </system.web>
</configuration>

should see you right

这篇关于如何设置在web.config中会话超时的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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