% myip=Request.ServerVariables("REMOTE_ADDR") myrefer=Request.ServerVariables("SERVER_NAME") & Request.ServerVariables("URL") mybrowser=Request.ServerVariables("HTTP_USER_AGENT") mytime=time mydate=date myuser=Request.ServerVariables("REMOTE_USER") myhost=Request.ServerVariables("REMOTE_HOST") %> <% Set MyConn=Server.CreateObject("ADODB.Connection") MyConn.Open "CFAA" mysql="INSERT INTO grabem (ipnum, refer,browser,currtime,currdate,remuser,remhost)VALUES('"&myip&"','"&myrefer&"','"&mybrowser&"','"&mytime&"','"&mydate&"','"&myuser&"','"&myhost&"')" set RS=MyConn.Execute(mysql) %> <% thedate=date thepage="default.asp" grabsql="SELECT pagename, permcount, today, todaycount FROM mystats WHERE pagename='"&thepage&"'" putsql="INSERT INTO mystats(pagename, permcount, today, todaycount) VALUES ('"&thepage&"', '1', '"&thedate&"', '1')" updatesql="UPDATE mystats SET permcount=permcount+1, todaycount=todaycount + 1 WHERE pagename='"&thepage&"'" updatedatesql="UPDATE mystats SET today='"&thedate&"', permcount=permcount+1, todaycount=1 WHERE pagename='"&thepage&"'" set RS=MyConn.Execute(grabsql) permcount=RS("permcount") today=RS("today") todaycount=("todaycount") if RS.EOF then set RS=MyConn.Execute(putsql) Else permcount=RS("permcount") today=RS("today") todaycount=RS("todaycount") end if if today=thedate then todaycount=todaycount + 1 permcount=permcount + 1 set RS=MyConn.Execute(updatesql) end if if today <> thedate then todaycount = 0 set RS=MyConn.Execute(updatedatesql) end if %> <% allsql="SELECT * FROM mystats" grabsql="SELECT pagename, permcount, today, todaycount FROM mystats WHERE pagename = '"&thepage&"'" set RS=MyConn.Execute(allsql) set RS=MyConn.Execute(grabsql) permcount=RS("permcount") today=RS("today") todaycount=RS("todaycount") set RS=Nothing MyConn.Close %>
|
|
Inspiring Career, Life and Business Leadership .....One person at a time.
Leadership at the speed of life does! That’s why leaders nationwide rely on LeadNow coaching and performance tools - to guarantee success.
Contact Us:
| |||||||||||||||||
|
Our
Business Our Success
Partners
Leadnow Personal Coaching
Leadnow Business Coaching
Contact Us Send mail to
WebInfo@leadnow.com with
questions or comments about this web site.
|