Forum Moderators: phranque

Message Too Old, No Replies

[.htaccess] exclude files from being logged

         

siMKin

9:48 am on Jul 6, 2005 (gmt 0)

10+ Year Member



I'm looking for a way to exclude files from being logged, without having to be the owner of the server.
I know it can be done with conditional logs [httpd.apache.org], but it may be apparent that this does not satisfy my goal.

So, i was hoping it could be done with a .htaccess file. I've been googling a lot, but cannot find the answer.

Anyone?
Thnx in advance

jdMorgan

6:16 pm on Jul 6, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



For security reasons, this capability is not extended to the "user" level in .htaccess.

Jim

jatar_k

6:25 pm on Jul 6, 2005 (gmt 0)

WebmasterWorld Administrator 10+ Year Member



your only option would be to write a parser that could sort the files for you after the fact

then you could use those parsed files for stats or whatever you need

siMKin

5:57 am on Jul 7, 2005 (gmt 0)

10+ Year Member



I'm not sure that i understand what you mean jatar_k ...

marcs

6:21 am on Jul 7, 2005 (gmt 0)

10+ Year Member



Basically, your host would not want you to exclude certain files from showing up in logs. They likely use this to calculate traffic usage on port 80. This is likely why this was excluded from something you could to in .htaccess

jatar_k was suggesting you exclude the unwanted entries from your log file(s) prior to running whatever script you want to run on log files. On *nix systems, use grep -v "exclude_whatever", pipe to a new file and run your script on the new file.