📄 ad_tj.asp
字号:
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<meta http-equiv="Content-Language" content="zh-cn">
<link rel="stylesheet" type="text/css" href="inc/css.css">
<!--#include file="tj_config.asp"-->
<%
if session.Contents("master")=false and whatcan<0 then Response.Redirect "tj_help.asp?id=004&error=本统计系统管理员不允许访客查看任何信息。"
set conn=server.createobject("adodb.connection")
DBPath = Server.MapPath(connpath)
conn.Open "driver={Microsoft Access Driver (*.mdb)};dbq=" & DBPath
tmprs=conn.execute("Select vtop,starttime from vjian")
vtotal=tmprs("vtop")
vfirst=tmprs("starttime")
set tmprs=nothing
if isnull(vtotal) then vtotal=0
if vtotal=0 then
conn.Close
set conn=nothing
Response.Redirect "tj_help.asp?id=007&error=统计系统还没有启用,尚不能查看统计报告。"
end if
'在线人数
Set rs = Server.CreateObject("ADODB.Recordset")
sql="select vip from view where vtime >= dateadd('n',-20,now()) group by vip"
rs.Open sql,conn,1,1
vonline=rs.RecordCount
rs.Close
set rs=nothing
'今日访问量、昨日访问量(从简数据朝读取)
tmprs=conn.execute("Select today,yesterday from vjian")
vtoday=tmprs("today")
vyesterday=tmprs("yesterday")
if isnull(vtoday) then vtoday=0
if isnull(vyesterday) then vyesterday=0
'今年访问量
tmprs=conn.execute("Select count(id) as vthisyear from view where vyear=" & year(now))
vthisyear=tmprs("vthisyear")
if isnull(vthisyear) then vthisyear=0
'本月访问量
tmprs=conn.execute("Select count(id) as vthismonth from view where vmonth=" & month(now) & " and vyear=" & year(now))
vthismonth=tmprs("vthismonth")
if isnull(vthismonth) then vthismonth=0
'访问天数、平均每天访问量
vdays=now()-vfirst
vdayavg=vtotal/vdays
vdays=int((vdays*10^mPrecision)+0.5)/(10^mPrecision)
if vdays<1 then vdays="0" & vdays
vdayavg=int((vdayavg*10^mPrecision)+0.5)/(10^mPrecision)
'预计今日访问量
vdaylong=now()-date()
vguess=int(((vtoday/vdaylong)+vyesterday)/2+0.5)
if vguess< vtoday then vguess=int((vtoday/vdaylong)+0.5)
'当前用户放量
vuser=cint(Request.Cookies(mNameEn)("lao"))
conn.Close
set conn=nothing
%>
<!--#include file="tj_top.asp"-->
<br>
<table width="500" cellspacing="0" align="center" cellpadding="0" border="0">
<tr><td colspan="4"><img src="img/photoup.gif"></td></tr>
<tr height="30">
<td width="1" class="backs"></td>
<td colspan="2" width="489"class="backq">
<img src="img/tb_title.gif" align=absmiddle> ∷∷∷ 总 体 数 据 ∷∷∷
</td>
<td width="1" class="backs"></td>
</tr>
<tr height="50">
<td width="1" class="backs"></td>
<td width="220"class="backq" valign=top>
<p style="line-height: 140%; margin-left: 25; margin-right: 0; margin-top: 10; margin-bottom: 5" align=left>
总访问量: <%=vtotal+old_count%><br>
用本系统前: <%=old_count%><br>
用本系统后: <%=vtotal%><br>
在线人数: <%=vonline%><br>
您的访问量: <%=vuser%><br>
开始统计于: <%=vfirst%><br>
今日访问量: <%=vtoday%><br>
昨日访问量: <%=vyesterday%><br>
今年访问量: <%=vthisyear%><br>
本月访问量: <%=vthismonth%><br>
统计天数: <%=vdays%><br>
平均日访量: <%=vdayavg%><br>
预计今日: <%=vguess%><br>
</td>
<td width="1" class="backs"></td>
</tr>
<tr><td colspan="4"><img src="img/photodown.gif"></td></tr>
</table>
<br>
<!--#include file="tj_bottom.asp"-->
</body>
</html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -