📄 index.asp
字号:
<!--#include file="top.asp" -->
<%
'******************************
'
' 『头发乱了』访客单用户统计系统
' 张金义 2001_jinge@sohu.com
' http://www.99321.com
'
' 版权所有: 哈哈大侠
'
'******************************
%>
<% '------删除---
sql11="select count(fid) as alldayweek from fcount"
set rs11=conn.execute(sql11)
maxalldayweek=rs11("alldayweek")
if maxalldayweek>tmax then
sql="delete fid from fcount"
conn.execute(sql)
end if
set rs11=nothing
fyear=year(now)'判断当前年份
fmonth=month(now)'判断当前月份
fday=day(now)'判断当前日期
fweek=weekday(now)'判断当前星期
fweeknum=Datepart("ww",now())'判断当前周数
sql="select * from vcount"
set rs=conn.execute(sql)
vyear=rs("vnowyear")'今年访问量
vmonth=rs("vnowmonth")'今月访问量
vpremonth=rs("vpremonth")'上个月访问量
vweek=rs("vweek")'今周访问量
vtoday=rs("vtoday")'今日访问量
vyestaday=rs("vyestaday")'昨日访问量
vtotal=rs("vtotal")'总访问量
vtotal1=rs("vtotal1")'ip总访问量
vstarttime=rs("vstarttime")'开始统计时间
set rs=nothing
vdatecount=round((now()-vstarttime),2)'统计天数
if vdatecount=0 then vdatecount=1
vavercount=round((vtotal/vdatecount),2)'平均访问量
vdaylong=now()-date()
vguesstoday=int(((vtoday/vdaylong)+vyesterday)/2+0.5)
if vguesstoday< vtoday then vguesstoday=int((vtoday/vdaylong)+0.5)'预计今日访问量
'--------统计在线人数--------
set rs2 = server.createobject("adodb.recordset")
sql2="select distinct fip from fcount where ftime >= dateadd('n',-"&onlinetime&",now()) order by fip"
rs2.Open sql2,conn,1,1
fonline=rs2.RecordCount
rs2.Close
'--------结束统计--------
%>
<BODY aLink=#90d5e5 bgColor=#ffffff link=#90d5e5 text=#666666 topMargin=0
vLink=#90d5e5>
<DIV align=center><BR>
<TABLE border=0 cellPadding=0 cellSpacing=0
style="COLOR: #272727; FONT-SIZE: 10pt">
<TBODY>
<TR>
<TD height=18 width=18><IMG height=18 src="img/t-ani2-a1.gif" width=18></TD>
<TD background=img/t-ani2-a2.gif></TD>
<TD height=18 width=26><IMG height=18 src="img/t-ani2-a3.gif" width=26></TD></TR>
<TR>
<TD background=img/t-ani2-a4.gif></TD>
<TD bgColor=#ffffff height=270 width=<%=tdc3%>>
<div align="center">
<table border=1 borderColor=<%=tdc2%> cellPadding=4 cellSpacing=1 style="border-collapse: collapse" align=center >
<tr>
<td colspan="4" align="center" <%=hColor1%> class=tdc1 height="23">
总体数据</td>
</tr>
<tr>
<td class=tdc height="22" bgcolor=<%=tcolor2%> width="20%">总访问量:</td><td class=tdc bgcolor=<%=tcolor2%> height="22" width="22%"><%=vtotal%></td>
<td class=tdc bgcolor=<%=tcolor2%> height="22" width="20%" align="left">站点名称:</td><td class=tdc bgcolor=<%=tcolor2%> height="22"><%=hometitle%></td></tr>
<tr>
<td class=tdc height="22" bgcolor=<%=tcolor2%> width="20%">今年访问量:</td><td class=tdc bgcolor=<%=tcolor2%> height="22" width="22%"><%=vyear%></td>
<td class=tdc bgcolor=<%=tcolor2%> height="22" width="20%" align="left">
站点地址:</td><td class=tdc bgcolor=<%=tcolor2%> height="22"><a href='<%=homeurl%>' target=_blank><%=homeurl%></a></td></tr>
<tr>
<td class=tdc height="22" bgcolor=<%=tcolor2%> width="20%">今月访问量:</td><td class=tdc bgcolor=<%=tcolor2%> height="22" width="22%"><%=vmonth%></td>
<td class=tdc bgcolor=<%=tcolor2%> height="22" width="20%" align="left">
站长名称:</td><td class=tdc bgcolor=<%=tcolor2%> height="22"><%=homebanzhu%></td></tr>
<tr>
<td class=tdc height="22" bgcolor=<%=tcolor2%> width="20%">上月访问量:</td><td class=tdc bgcolor=<%=tcolor2%> height="22" width="22%"><%=vpremonth%></td>
<td class=tdc bgcolor=<%=tcolor2%> height="22" width="20%" align="left">
站长信箱:</td><td class=tdc bgcolor=<%=tcolor2%> height="22"><a href='mailto:<%=homeemail%>'><%=homeemail%></a></td></tr>
<tr>
<td class=tdc height="22" bgcolor=<%=tcolor2%> width="20%">今周访问量:</td><td class=tdc bgcolor=<%=tcolor2%> height="22" width="22%"><%=vweek%></td>
<td class=tdc bgcolor=<%=tcolor2%> height="22" width="20%" align="left">
站点简介:</td>
<td class=tdc bgcolor=<%=tcolor2%> height="110" rowspan="5" valign="top"><%=homecontent%></td>
</tr>
<tr>
<td class=tdc height="22" bgcolor=<%=tcolor2%> width="20%">今日访问量:</td><td class=tdc bgcolor=<%=tcolor2%> height="22" width="22%"><%=vtoday%></td>
<td class=tdc bgcolor=<%=tcolor2%> height="22" width="20%"></td></tr>
<tr>
<td class=tdc height="22" bgcolor=<%=tcolor2%> width="20%">昨日访问量:</td><td class=tdc bgcolor=<%=tcolor2%> height="22" width="22%"><%=vyestaday%></td>
<td class=tdc bgcolor=<%=tcolor2%> height="22" width="20%"></td></tr>
<tr>
<td class=tdc height="22" bgcolor=<%=tcolor2%> width="20%">当前在线人数:</td><td class=tdc bgcolor=<%=tcolor2%> height="22" width="22%"><%=fonline%></td>
<td class=tdc bgcolor=<%=tcolor2%> height="22" width="20%"></td></tr>
<tr>
<td class=tdc height="22" bgcolor=<%=tcolor2%> width="20%">用本系统前:</td><td class=tdc bgcolor=<%=tcolor2%> height="22" width="22%"><%=startcount%></td>
<td class=tdc bgcolor=<%=tcolor2%> height="22" width="20%"></td></tr>
<tr>
<td class=tdc height="22" bgcolor=<%=tcolor2%> width="20%">用本系统后:</td><td class=tdc bgcolor=<%=tcolor2%> height="22" width="22%"><%=vtotal%></td>
<td class=tdc bgcolor=<%=tcolor2%> height="22" width="20%">
IP总访问量:</td><td class=tdc bgcolor=<%=tcolor2%> height="22"><%=vtotal1%></td>
</tr>
<tr>
<td class=tdc height="22" bgcolor=<%=tcolor2%> width="20%">开始统计时间:</td><td class=tdc bgcolor=<%=tcolor2%> height="22" width="22%"><%=vstarttime%></td>
<td class=tdc bgcolor=<%=tcolor2%> height="22" width="20%">你的访问量:</td><td class=tdc bgcolor=<%=tcolor2%> height="22"><%=request.Cookies(homeurl)("feiyue")%></td>
</tr>
<tr>
<td class=tdc height="22" bgcolor=<%=tcolor2%> width="20%">总共统计天数</td><td class=tdc bgcolor=<%=tcolor2%> height="22" width="22%"><%=vdatecount%></td>
<td class=tdc bgcolor=<%=tcolor2%> height="22" width="20%">平均日访量:</td><td class=tdc bgcolor=<%=tcolor2%> height="22"><%=vavercount%></td>
</tr>
<tr>
<td class=tdc height="22" bgcolor=<%=tcolor2%> width="20%">预计今日访问量</td><td class=tdc bgcolor=<%=tcolor2%> height="22" width="22%"><%=vguesstoday%></td>
<td class=tdc bgcolor=<%=tcolor2%> height="22" width="20%"></td><td class=tdc bgcolor=<%=tcolor2%> height="22"></td></tr></table>
</div><!--#include file="bq.asp" --></TD>
<TD background=img/t-ani2-a5.gif></TD></TR>
<TR>
<TD height=26 width=18><IMG height=26 src="img/t-ani2-a6.gif" width=18></TD>
<TD background=img/t-ani2-a7.gif></TD>
<TD height=26 width=26><IMG height=26 src="img/t-ani2-a8.gif" width=26></TD></TR></TBODY></TABLE></DIV>
</BODY>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -