Snitz Forums 2000
Snitz Forums 2000
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 Snitz Forums 2000 MOD-Group
 MOD Add-On Forum (W/Code)
 User Log
 New Topic  Topic Locked
 Printer Friendly
Next Page
Author Previous Topic Topic Next Topic
Page: of 5

GauravBhabu
Advanced Member

4288 Posts

Posted - 08 December 2001 :  14:21:59  Show Profile
USER LOG
  • This will record Date and time,UserIP,PageVisited,UserName.

  • This can only be used on a server with the Scripting.FileSystemObject fully enabled.




Active Users Mod Installed:


Find the following statements in inc_activeusers.asp

'CHECK IF USER NAME AND IP ADDRESS MATCH
set rsWho = Server.CreateObject("ADODB.Recordset")


Add the following statements Just before the above statements in inc_activeusers.asp

dim iplg, logFile8
set iplg=server.createObject("scripting.FileSystemObject")
set logFile8=iplg.openTextFile(server.mappath("/forum/FOLDERNAME/IPLOG.txt"),8)
logFile8.write strOnlineCheckInTime & Chr(9) & strOnlineUserIP & CHR(9) & strScriptName & CHR(9) & strOnlineUser & vbCrLf
logFile8.close
set logFile8=nothing
set iplg=nothing


ActiveUsers Mod not installed

Add the following statements at the end of inc_top.asp

<%strOnLineCheckInTime = DateToStr(strForumTimeAdjust)
strOnlineUserIP = Request.ServerVariables("REMOTE_ADDR")
strScriptName = Request.servervariables("script_name")
if strDBNTUserName = "" then
strOnlineUser = "Guest"
else
strOnlineUser = strDBNTUserName
end if

dim iplg, logFile8
set iplg=server.createObject("scripting.FileSystemObject")
set logFile8=iplg.openTextFile(server.mappath("/forum/FOLDERNAME/IPLOG.txt"),8)
logFile8.write strOnlineCheckInTime & Chr(9) & strOnlineUserIP & CHR(9) & strScriptName & CHR(9) & strOnlineUser & vbCrLf
logFile8.close
set logFile8=nothing
set iplg=nothing%>



Create a text file and name it IPLOG.txt and place it in a folder where you have read/write permissions enabled.

Replace FOLDERNAME with the folder name where you have placed your IPLOG.txt file.

That is it.


GauravBhabu - It is difficult to IMPROVE on Perfection, There is no harm in Keep Trying.

Edited by - GauravBhabu on 17 February 2002 20:49:20

Extra Sports
Average Member

USA
644 Posts

Posted - 08 December 2001 :  14:49:58  Show Profile
do we have to add this anywhere??

'CHECK IF USER NAME AND IP ADDRESS MATCH
set rsWho = Server.CreateObject("ADODB.Recordset")


Like sports?
Register at extrasports!!!
www.extrasports.2ya.com
Go to Top of Page

Extra Sports
Average Member

USA
644 Posts

Posted - 08 December 2001 :  14:51:12  Show Profile
oh, nevermind. I haven't read the directions. LOL. I really need this for sure. thanks!!


Like sports?
Register at extrasports!!!
www.extrasports.2ya.com
Go to Top of Page

Extra Sports
Average Member

USA
644 Posts

Posted - 08 December 2001 :  16:09:45  Show Profile
ok, it works great. This is useful!!!


Like sports?
Register at extrasports!!!
www.extrasports.2ya.com
Go to Top of Page

GauravBhabu
Advanced Member

4288 Posts

Posted - 08 December 2001 :  16:26:03  Show Profile
The information can be used to track someone abusing your forums using different usernames.


GauravBhabu - It is difficult to IMPROVE on Perfection, There is no harm in Keep Trying.
Go to Top of Page

Extra Sports
Average Member

USA
644 Posts

Posted - 15 December 2001 :  23:18:54  Show Profile
yea, and if somebody hacks my site again, I will call cops on them. LOL. Thanks alot for this!!!


Like sports?
Register at extrasports!!!
www.extrasports.2ya.com
Go to Top of Page

bjlt
Senior Member

1144 Posts

Posted - 16 December 2001 :  03:00:02  Show Profile
this is really useful.

I have a question on permissions:

here's what I have in my control pannel
-----------------
Permissions for: xxxxxx log.txt

USERNAME READ WRITE
ownername ENABLED ENABLED
_DISABLED_GUEST ENABLED ENABLED
_DISABLED_GUEST ENABLED ENABLED
ANONYMOUS ENABLED ENABLED

-----------------

I have to set anonymous to write enabled
will this cause any trouble? does it mean others are possible to write to log.txt?

btw, what does _DISABLED_GUEST mean here? (i'll ask the system admin for this if this is not a global setting for win2000 servers)

thanks.


Go to Top of Page

fpgal
New Member

93 Posts

Posted - 01 February 2002 :  02:48:38  Show Profile
Thank you!!!!

This is an awesome script - exactly what I need!

Only one question: Is there a simple way to make it track and record the forum/topic ID or Name also?


fpgal



Edited by - fpgal on 01 February 2002 02:55:51
Go to Top of Page

suhern
Junior Member

186 Posts

Posted - 01 February 2002 :  05:05:01  Show Profile
It works very nicely but when I look into the log it shows date, ip address, and name but not pagevisited. I am behind a firewall when I tested this. Is this the cause of it?

Go to Top of Page

GauravBhabu
Advanced Member

4288 Posts

Posted - 01 February 2002 :  05:53:25  Show Profile
Make sure you have strScriptName variable defined and is being populated.

Look for this statement in inc_top.asp

strScriptName = Request.servervariables("script_name")


www.forumSquare.com - GauravBhabu - It is difficult to IMPROVE on Perfection, There is no harm in Keep Trying.
Go to Top of Page

suhern
Junior Member

186 Posts

Posted - 01 February 2002 :  11:06:31  Show Profile
quote:

Make sure you have strScriptName variable defined and is being populated.

Look for this statement in inc_top.asp

strScriptName = Request.servervariables("script_name")


www.forumSquare.com - GauravBhabu - It is difficult to IMPROVE on Perfection, There is no harm in Keep Trying.



I checked and do have that statement in my inc_top. Any idea why the pagename is not showing up in the log?

Go to Top of Page

GauravBhabu
Advanced Member

4288 Posts

Posted - 01 February 2002 :  14:00:32  Show Profile
Add the statement in red as shown in inc_top.asp and see if the variable is getting populated.
strScriptName = Request.servervariables("script_name")
Response.write "Scriptname:" & strScriptName


www.forumSquare.com - GauravBhabu - It is difficult to IMPROVE on Perfection, There is no harm in Keep Trying.
Go to Top of Page

Kong
Junior Member

100 Posts

Posted - 03 February 2002 :  05:39:12  Show Profile
quote:

Make sure you have strScriptName variable defined and is being populated.

Look for this statement in inc_top.asp

strScriptName = Request.servervariables("script_name")




I'm interested in this but have a slight problem.

I looked inside of inc_top.asp to make sure I had that set but couldn't find that line anywhere.

What is that line for?
Is there something I'm missing that I comes with?

_________________________
Come on by and visit Deth Incarnate.
Growing slowly, but growing none the less.
Go to Top of Page

GauravBhabu
Advanced Member

4288 Posts

Posted - 03 February 2002 :  07:47:40  Show Profile
Do you have active users Mod installed? If not then use the code for Active uses Mod not installed.

www.forumSquare.com - GauravBhabu - It is difficult to IMPROVE on Perfection, There is no harm in Keep Trying.
Go to Top of Page

dayve
Forum Moderator

USA
5820 Posts

Posted - 03 February 2002 :  12:00:50  Show Profile  Visit dayve's Homepage
here's an idea to a really good logging mod G. I was thinking of
checking the date and creating new logs for every month of the year
which will slim down the size of the log file and conveniently would
offer separate files for reviewing by month. my log file is already
5 megs in a matter of 2 weeks.

oh yeah, as a side note, I review this log quite frequently and
actually found someone trying to get to my admin areas several times
which allowed me to eventually ban them by ip.

____________
dayve@burningsouls.com


http://www.nineinchnailz.com - your source for everything nine inch nails !

Edited by - dayve on 03 February 2002 12:02:19
Go to Top of Page

SimonT
Junior Member

United Kingdom
202 Posts

Posted - 03 February 2002 :  12:07:58  Show Profile
I also have the same problem I have the latest version of the active users build (I think rewritten by nathan not your build)
I have looked in to the log file and I do not see where the user is. I have looked in the inc_top.asp file but I do not have the line

strScriptName = Request.servervariables("script_name")

Let me know if you would like to see any of my files
Go to Top of Page
Page: of 5 Previous Topic Topic Next Topic  
Next Page
 New Topic  Topic Locked
 Printer Friendly
Jump To:
Snitz Forums 2000 © 2000-2021 Snitz™ Communications Go To Top Of Page
This page was generated in 0.27 seconds. Powered By: Snitz Forums 2000 Version 3.4.07