首页 » 默认不分类 » 获取asp网站中的所有session

获取asp网站中的所有session

如果你的虚拟主机经常出现Service Unavailable或经常自动退出后台,那么可能是session丢失太快,可以用下面的代码来查看到我的程序到底占用了多少session,通过这些数据管理员也可得到分析帮助。

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
<%
Response.Write "总共Session数:" & Session.Contents.Count & "<br>"
Dim strName, iLoop
 
for each strName in Session.Contents
 
  If IsArray(Session(strName)) then
    For iLoop = LBound(Session(strName)) to UBound(Session(strName))
       Response.Write strName(iLoop) & " – " & Session(strName(iLoop)) & "<br>"
    Next
  Else
  Response.Write strName & " – " & Session.Contents(strName) & "<br>"
  End If
next
%>

,

转发到新浪微博 转发到新浪微博

目前这篇文章有1条评论(Rss)

  1. porno | #1
    05/17/2012 at 09:42

    escort hanım eskortlar euro bayan sex

我要评论