|
|
| Version | 3.0.1.472 | | Rating |
| | Developer | Threeplicate Srl | | Updated | March 9, 2010 | | Homepage | N/A | | Works with | ScrewTurn Wiki v3.0.x | | License | GPLv2 |
|
More about this Plugin
The
Download Counter Plugin allows you to count the number of times a file or attachment was downloaded.
Configuration
Once installed (no configuration needed), you can use the following markup anywhere in your wiki:
<countDownloads pattern="..."[ startDate="yyyy/mm/dd"]>
<file name="..."[ provider="..."] />
<attachment name="..." page="..."[ provider="..."] />
</countDownloads>
The
pattern attribute determines the output text of the formatter. It can contain any string and any of the following placeholders (case insensitive):
- #COUNT#: total download count
- #DAILY#: downloads per day
- #WEEKLY#: downloads per week
- #MONTHLY#: downloads per month.
startDate is the date used for calculating the daily, weekly and monthly downloads values. If omitted,
January 1st, 2009 is assumed.
The
countDownloads root tag can contain one or more
file and
attachment elements. The
name attribute is respectively the full name of the file or the name of the attachment. The optional
provider attribute is the full type name of the files storage provider that manages the file or attachment. If omitted, the default provider is assumed. For attachment elements, the
page attribute specifies the name of the page the attachment belongs to.
The output of the plugin is determined by the
pattern attribute. The pattern string is rendered, replacing the placeholders with their respective calculated values.
For example, a pattern string formed as follows:
Downloads: #count# (#weekly# downloads per week)
Would generate an output like this:
Downloads: 1234 (45 downloads per week)
Caching
The plugin caches its output for 5 minutes, so that the load against the data storage is reduced.
Discuss
No Messages for this Page. Be the first!