Current User: Guest Login
Please consider registering

Lost Your Password?

Search Forums:


Minimum search word length is 4 characters – Maximum search word length is 84 characters
Wildcard Usage:
*  matches any number of characters    %  matches exactly one character

Trouble with "Hits on HTML"

Reply to Post Add a New Topic

4:16 pm
January 7, 2010

Drew Wrobel


I took the code from Hits on Images and modified it to get the hits on various HTML files.

I get a new section ‘Hits on HTML’, I am not getting any results listed.

The normal awstats listing under 'File types' does show stats for the various html files that I'm checking for.

Here is the code that I have defined:

ExtraSectionName7="Hits on HTML (Top 10)"
ExtraSectionCodeFilter7="200 304″
ExtraSectionFirstColumnTitle7="HTML/Script File"
ExtraSectionFirstColumnFormat7="<A HREF='%s' TARGET='_blank'>%s</A>"

Here is a copy of a URL from the squid access log:

http :// –
- [30/Nov/2009:10:25:57 -0500] "GET ht
tp:// HTTP
/1.1″ 301 563 "-" "msnbot/2.0b (+http:

9:14 pm
January 7, 2010



posts 1125

I don't see any error in your extra section.

Note that the new extra section appears iin the report as soon as you add it to the AWStats config file, but there will be no data until the next AWStats data update.

2:59 pm
January 8, 2010

Drew Wrobel


I was hoping that I missed something.

Yeah, I learned the hard way with making changed to the awstats configuration and having to wait until the next update.

I have gone through a couple of updates and I'm still not getting any stats in the new section.

Any ideas/suggestions for what I can do to see why the extra rule isn't picking up html while the normal awstats is listing hits under the File type section?

3:51 pm
January 8, 2010



posts 1125

I just noticed that, in your post above, there is a right double quote  at the end of the second line. It should be a double quotation mark :

ExtraSectionCodeFilter7="200 304"

Not sure that this is related to your problem though.

5:34 pm
January 8, 2010

Drew Wrobel


I checked my configuration file and a double quotation mark.

Not sure what happened that it didn't post to the forum correctly.

I'm doing to make a copy of my configuration, and take out all the extra sections but this one.

See if I get any different results.

8:14 pm
January 12, 2010

Drew Wrobel


I ran a report with awstats and debug set to 10.

It turns out the reason why I'm not getting any hits in my report is that the URLs' have a http code of 404  or 301.

I guess the File type section only lists the filetypes, regardless of their HTTP return code.

Should I leave the CodeFilter option to 200 and 304 or should I include 404, 301 and 302 as well?

9:12 pm
January 12, 2010



posts 1125

The ValidHTTPCodes  directive applies to all sections but the extra sections. Its default value is :

ValidHTTPCodes="200 304"

Does ValidHTTPCodes  have another value in your config file ? If yes, you need to change ExtraSectionCodeFilter7  accordingly.

4:26 pm
January 13, 2010

Drew Wrobel


I checked ValidHTTPCodes and the directive is set at the default value.

Was hoping to get an idea of what HTML files were being hit that are generating the bandwidth, but if they are from 301, 302 and 404, not sure that will by me anything.

Reply to Post

Reply to Topic:
Trouble with "Hits on HTML"

Guest Name (Required):

Guest Email (Required):

NOTE: New Posts are subject to administrator approval before being displayed

Confused Cool Cry Embarassed Frown Kiss Laugh Smile Surprised Wink Yell
Post New Reply

Guest URL (required)

Math Required!
What is the sum of:
9 + 9

About the Forum

Forum Timezone: UTC 1

Most Users Ever Online: 302

Currently Online:
7 Guests

Currently Browsing this Topic:
1 Guest

Forum Stats:

Groups: 2
Forums: 9
Topics: 639
Posts: 2710


There are 257 Members
There have been 304 Guests

There is 1 Admin
There is 1 Moderator

Top Posters:

cssfsu – 55
deepakgupta – 34
albert_newton – 30
cosminpana – 20
DTNMike – 19
ahtshun83 – 17

Recent New Members: raju, todd2taylor, sbdcunha, mansigill1987, ThomasDuh, ThomasKic

Administrators: Jean-Luc (1125 Posts)

Moderators: Jean-Luc (1125 Posts)