⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 index.asp

📁 一个用户访问记录程序  基本功能 就是记录客户访问情况
💻 ASP
字号:
<!--#include file="top.asp" -->
<!--#include file="inc_admenu.asp"-->
<%
'******************************
'
'      飞越访客多用户统计系统
'    飞越   feiyueziwo@sohu.com 
'        www.pwsite.net
'
'     版权所有: 动力在线
'
'******************************
%>
<% if errornum<>1 then
fyear=year(now)'判断当前年份
fmonth=month(now)'判断当前月份
fday=day(now)'判断当前日期
fweek=weekday(now)'判断当前星期
fweeknum=Datepart("ww",now())'判断当前周数
sql="select * from vcount where vuser='"&view&"'"
set rs=conn.execute(sql)
if not rs.eof then
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")
end if
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()) and fuser='"&view&"' order by fip"
rs2.Open sql2,conn,1,1
if not rs2.eof then
	fonline=rs2.RecordCount
	else
	fonline=0
	end if
	rs2.Close
	'--------结束统计--------

	%>


<div align="center">
<table border=1 borderColor=<%=tdc2%> cellPadding=4 cellSpacing=1 width=<%=tdc3%> 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>
<%else%>
 <!--#include file="error.asp" -->
<%end if%><!--#include file="bq.asp" -->

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -