关于session的配置问题!!!!!谢谢指教. 如何配置session的时间?在config和iis中都可以吗?请大家指点一下,谢谢!可以设置成永远不过期的吗?希望大家能说的详细点,再次表示感谢 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 这个倒是没有设置过,在confing文件中应该可以设置 IIS似乎是比CONFIG管用,也许是水平不够。想要永不过期,为什么不用COOKIE。当然还有一个变态的办法:就是在每个页面中加一个隐藏的iframe定时刷新一下 <sessionState mode="[Off|InProc|StateServer|SQLServer|Custom]" timeout="number of minutes" cookieName="session identifier cookie name" cookieless= "[true|false|AutoDetect|UseCookies|UseUri|UseDeviceProfile]" regenerateExpiredSessionId="[True|False]" sqlConnectionString="sql connection string" sqlCommandTimeout="number of seconds" allowCustomSqlDatabase="[True|False]" useHostingIdentity="[True|False]" stateConnectionString="tcpip=server:port" stateNetworkTimeout="number of seconds" customProvider="custom provider name"> <providers>...</providers></sessionState>具体去msdn查查吧。 在刷新时间内 定时做些事情~~ 这样 session就会被更新了 1,iis中可以设置session过期在IIS站点的属性里,在主目录->配置->会话过期时间2,config中设置:<sessionState mode="InProc" stateConnectionString="tcpip=127.0.0.1:42424" sqlConnectionString="data source=127.0.0.1;Trusted_Connection=yes" cookieless="false" timeout="20"/>3,也可以页面代码内直接设置:比如加到pageload里session.timeout=20 sql where 条件为日期 一条查询语句,在线等,谢谢 .Net截取字符串影响布局 请教点关于CommandField中编辑列的文本框长度设置。。 关于个多个Web.config基于Form验证的问题 熟悉MS SQL存儲過程 文章审批流程,数据库表如果设计,求思路 图片放在数据库好还是直接以文件的形式存在好? 想做错误异常发布器,请教该如何做? 菜鸟小问题 小弟要换工作了,在此求一份个人简历样式啊,谢谢大家了啊。 asp.net处理大量字符串(处理服务器返回来的大量字符串)
想要永不过期,为什么不用COOKIE。
当然还有一个变态的办法:
就是在每个页面中加一个隐藏的iframe定时刷新一下
mode="[Off|InProc|StateServer|SQLServer|Custom]"
timeout="number of minutes"
cookieName="session identifier cookie name"
cookieless=
"[true|false|AutoDetect|UseCookies|UseUri|UseDeviceProfile]"
regenerateExpiredSessionId="[True|False]"
sqlConnectionString="sql connection string"
sqlCommandTimeout="number of seconds"
allowCustomSqlDatabase="[True|False]"
useHostingIdentity="[True|False]"
stateConnectionString="tcpip=server:port"
stateNetworkTimeout="number of seconds"
customProvider="custom provider name">
<providers>...</providers>
</sessionState>
具体去msdn查查吧。
在IIS站点的属性里,在主目录->配置->会话过期时间2,config中设置:
<sessionState mode="InProc" stateConnectionString="tcpip=127.0.0.1:42424" sqlConnectionString="data source=127.0.0.1;Trusted_Connection=yes" cookieless="false" timeout="20"/>3,也可以页面代码内直接设置:
比如加到pageload里
session.timeout=20