1 post tagged “tagging”
WebTrends tracking works by placing tags (a few lines of script) into the HTML of a web page. From that page there may be a link to a downloadable file such as a PDF, but because that file is not a web page it cannot be tracked.
The workaround to ensure that download activity is recorded is to track clicks on the links that lead to the download of the files.
If you wanted to track a link that leads to a PDF download you need to incorporate the following WebTrends code into the page’s HTML:
Exampleonclick="dcsMultiTrack('DCS.dcsuri', '/pdfdownloads/pdfname.pdf', 'WT.ti','PDFName');"
In standard HTML we can assume a link, to the PDF of an application form, looks like this in the source code:
<a href='/common/pdf/appform.pdf'>Click here to download</a>
To include the WebTrends code above into the HTML of the download it needs to be edited to look like this:
<a href='/common/pdf/appform.pdf' onclick="dcsMultiTrack('DCS.dcsuri','/common/pdf/appform.pdf','WT.ti',
'Application Form');">Click here to download</a>
NB:
1. The WT.ti parameter allows you to give a title to the download so that the report in WebTrends does not just show the URL. In the example above, we used the title Application Form.
2. WebTrends will not capture downloads if they are referred by a JavaScript function. Eg: openPDFWindow("appform.pdf");