Awstats apparently counts .exe and .dmg files as page views, instead of as downloads. I would like it to count them as downloads instead. How can I achieve that? How does Awstats determine whether something is a page view or a download?
I know about the extra section support, but I don't want a separate section, as I have downloads of many different types on my site, most of which are correctly listed as downloads. I would just like for .exe and .dmg files to appear there as well.
I figured it out myself by reading the code. It turns out that this information is in the
mime.pmreference file which awstats reads at startup. On my Ubuntu system this file is in/usr/share/awstats/lib. It contains lines like this:It maps extensions to a family and a file type, which can be empty or
pfor a page,ifor an image ordfor a download. It's easy to change the file type here, and to add missing extensions. I just changed the''next to'exe'to'd', and added a line for thedmgtype.You'll have to reprocess your log files if you want to fix your existing statistics.