This plugin shows file listings of media directories. It was inspired by the dirlisting plugin. It has many options and flags to control the generated listing.
{{medialisting>[options] [flags]}}
=). ”) like title=“Download Section”.| Option | Description | Example |
|---|---|---|
| dir | root directory for listing (this is a sub dir under the media folder) | dir=“docs” |
| mask | filter for directory items matched against their base name (this is regular expression) | mask=“\.pdf$” or mask=“\.(pdf|zip)$” |
| title | title of listing (the pipe sign forces a line break) | title=“File Index” |
| sort | sort items by a field: (basename, fullname, size, mtime, ctime (default is basename) | sort=“size” |
| limit | restrict how many items are displayed | limit=“2” |
| Flag | Description |
|---|---|
| size | shows file size in human readable form |
| ctime | shows file creation date and time in format YYYY-MM-DD |
| mtime | shows file modification date and time (same format like ctime) |
| commalist | does not render a table but a comma separated list of directory items (comma lists are always aligned to the left) |
| reverse | reverts sort order |
| recursive | includes sub directories |
| header | displays header |
| nice | beautifies file names by changing underscores to blanks and removing file extensions |
| small | generates a single column table without fixed width |
Download files in zip or compressed tar format:
| plugin_medialisting_latest.zip | 7 | Kb | 2007-01-21 |
| plugin_medialisting_latest.tar.gz | 5 | Kb | 2007-01-21 |
| plugin_medialisting_2007-01-21.zip | 7 | Kb | 2007-01-21 |
| plugin_medialisting_2007-01-21.tar.gz | 5 | Kb | 2007-01-21 |
| plugin_medialisting_2006-12-06.zip | 6 | Kb | 2006-12-06 |
| plugin_medialisting_2006-12-06.tar.gz | 5 | Kb | 2006-12-06 |
| plugin_medialisting_2006-11-05.zip | 6 | Kb | 2006-11-05 |
| plugin_medialisting_2006-11-05.tar.gz | 5 | Kb | 2006-11-05 |
* Some things
* {{medialisting>dir="images" mask=".*" limit=2 commalist nice}}
* More things
^Section^Files^
|Demo 1|{{medialisting>dir="images" mask=".*" reverse sort="mtime" limit=2 mtime ctime size}}|
|Demo 2|{{medialisting>dir="images" mask=".*" reverse sort="mtime" limit=2 mtime ctime size}}|
| Section | Files | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| Demo 1 |
|
||||||||||
| Demo 2 |
|
<divclass box half left green nobullets noindent|Left> {{medialisting>dir="images" mask=".*" limit="2" nice small}} </divclass|sorted> <divclass box half right red nobullets noindent|Right> {{medialisting>dir="images" mask=".*" limit="2" nice reverse small}} </divclass|reverse sorted>
{{medialisting>dir="images" mask=".*" reverse sort="mtime" limit=2 mtime ctime size header}}
{{medialisting>dir="images" mask=".*" reverse sort="mtime" limit=2 mtime ctime size small header}}