edit this page - page history - about editing

select template


Help

The Select Template is a complicated and powerful little tool to include in Wiki pages. It lets you generate parts of your page dynamically.

It's syntax is the same as normal include pages, except it's template name is $select. It takes parameters in the normal parameter-passing form.

Some examples:
{{$select|template=Template:Mine|link=Home|sort=title asc}}
Selects all pages that link to Home, sorts them by title ascending and displays them with the Template:Mine template.

{{$select|template=Template:Yours|link=Home|link=Editing|sort=inserted desc|seperator=Template:HR|removeCategory=1}}
Selects all pages that link to both Home and Editing, sorts them by most recently created first, and displays them with the Template:Yours template. Also seperates the links with the Template:HR template, and removes all Category tags.

Syntax

template=Title
Uses Title as the display template. Replaces {title} with the title of the selected page (i.e. the results).

link=Title
Selects all pages that link to this page, as well as the other links.

sort=sortkey
Sorts the results by some criteria.

seperator=Title
Uses Title as a seperator template, which is placed between results.

removeCategory=1
Removes ALL category tags, and not just the default tags that are removed (these are Category: Protected and Category: Template).

from=text
Selects all the text in the template page after this text.

to=text
Selects all text in the template page before this text.

start=n
Only selects results after the first n.

limit=n
Only selects n results.

count=1
Only select the count, and not the actual values. Instead of having elements to apply 'title' to, it instead has a variable 'count'. (See Statistics for an example.)

Valid sorts

Categories: Protected | Template | Help | Wiki

edit this page - what links to here? - page history - top
Last edited by jevon jevon 109 months ago
All lyrics are the properties of their original authors.

All code and intellectual property is copyright © Jevon Wright 2005.