Jump to content
toddcurry

Will Awstats Track Directly-Loaded File?

Recommended Posts

I am putting a document on a server that people will click to download (from inside a PDF). I'd like to see who downloaded the file, so I've turned to Awstats, but:

- the file is a PDF and there isn't a "PDF" category in the file listing (downloading a bigger PDF from a link embedded in a brief PDF).

- it isn't clear whether the file is tracked if it is "directly addressed"

 

Can anyone help shed some light on this? I tried RTFM for Awstats but can't stay awake doing so...

 

Thanks,

 

TC

 

Edited to make clear that downloadable doc is a pdf

Edited by toddcurry

Share this post


Link to post
Share on other sites

I would have thought it would come up under the 'pages' section. I get swf and rar files showing in there so can't see any reason why it wouldn't show pdf files.

Share this post


Link to post
Share on other sites

You can track individual files by modifying your AWStats configuration file.

 

>Take a look inside the AWStats config file to find the following part:
#-----------------------------------------------------------------------------
# EXTRA SECTIONS
#-----------------------------------------------------------------------------

AWStats – Monitor top file downloads

The following example will allow you to track the top downloads for a list of file types. 
Modify the list to suit your needs.

# To do: Ideally parameterize from not page list.
ExtraSectionName15="Downloads (diff,doc,pdf,rtf,sh,tgz,zip) - Top 10"
ExtraSectionCodeFilter15="200 304"
ExtraSectionCondition15="URL,(.*((\.diff)|(\.doc)|(\.pdf)|(\.rtf)|(\.sh)|(\.tgz)|(\.zip)))"
ExtraSectionFirstColumnTitle15="Download"
ExtraSectionFirstColumnValues15="URL,(.*)"
ExtraSectionFirstColumnFormat15="%s"
ExtraSectionStatTypes15=HBL
ExtraSectionAddAverageRow15=0
ExtraSectionAddSumRow15=1
MaxNbOfExtra15=10
MinHitExtra15=1

 

While you can modify the configuration file be aware if changes are made to the servers (newer version released) your changes may be lost or AWStats may not run.

Share this post


Link to post
Share on other sites

You can track individual files by modifying your AWStats configuration file.

 

 

 

Bruce, in what directory would I create the Awstats.yourTCHdomain.conf? (I just looked through all of my directories and cannot find an existing one). Also, permissions?

 

Thanks!!

 

TC

Share this post


Link to post
Share on other sites

Bruce, in what directory would I create the Awstats.yourTCHdomain.conf? (I just looked through all of my directories and cannot find an existing one). Also, permissions?

 

Thanks!!

 

TC

 

 

Oooops, googled a little off the TCH site and found it..... in /tmp

Share this post


Link to post
Share on other sites

Oooops, googled a little off the TCH site and found it..... in /tmp

 

 

You have lots of Extras in your .conf, Bruce -- and I don't even have an Extras section in my (stock) .conf file.

 

So for posterity, append this to the bottom of your conf file -- and watch for a line wrap if you copy/paste from here on the line that has the (.pdf)|//foo... "stuff"

>

LoadPlugin="geoipfree"

The above is the last line of my existing .conf file

 

and below is what I appended.

>
#-----------------------------------------------------------------------------
# EXTRA SECTIONS
#-----------------------------------------------------------------------------

# To do: Ideally parameterize from not page list.
ExtraSectionName1="Downloads (diff,doc,pdf,rtf,sh,tgz,zip) - Top 10"
ExtraSectionCodeFilter1="200 304"
ExtraSectionCondition1="URL,(.*((\.diff)|(\.doc)|(\.pdf)|(\.rtf)|(\.sh)|(\.tgz)|(\.zip)))"
ExtraSectionFirstColumnTitle1="Download"
ExtraSectionFirstColumnValues1="URL,(.*)"
ExtraSectionFirstColumnFormat1="%s"
ExtraSectionStatTypes1=HBL
ExtraSectionAddAverageRow1=0
ExtraSectionAddSumRow1=1
MaxNbOfExtra1=10
MinHitExtra1=1

Share this post


Link to post
Share on other sites

Yes, you need to add that to the config file. I don't do this anymore because an update caused the stats to stop running and I didn't feel like re-adding the code. Just copy/paste those lines into your config file at the end.

 

Yes, that is one line so don't let it wrap.

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...