Wiki Macros

Version 1
by (unknown)
Version 2
by (unknown)

Deletions or items before changed

Additions or items after changed

1 -
A macro inserts dynamic HTML data in any context supporting [Help:WikiFormatting Wiki Formatting].
+
A macro inserts dynamic HTML data in any context supporting [Help:WikiFormatting Wiki Formatting].
2 -
 
+
3 -
== Using Macros ==
+
== Using Macros ==
4 -
 
+
5 -
Macro calls are enclosed in two ''square brackets''.
+
Macro calls are enclosed in two ''square brackets''.
6 -
 
+
7 -
=== Examples ===
+
=== Examples ===
8 -
 
+
9 -
{{{
+
{{{
10 -
[[Timestamp]]
+
[[Timestamp]]
11 -
}}}
+
}}}
12 -
 
+
13 -
Display:
+
Display:
14 -
[[Timestamp]]
+
[[Timestamp]]
15 -
 
+
16 -
{{{
+
{{{
17 -
[[Resource(100)]]
+
[[Resource(100)]]
18 -
}}}
+
}}}
19 -
 
+
20 -
Display:
+
Display:
21 -
[[Resource(100)]]
+
[[Resource(100)]]
22 -
 
+
23 -
{{{
+
{{{
24 -
[[Tag(heattransfer)]]
+
[[Tag(heattransfer)]]
25 -
}}}
+
}}}
26 -
 
+
27 -
Display:
+
Display:
28 -
[[Tag(heattransfer)]]
+
[[Tag(heattransfer)]]
29 -
 
+
30 -
{{{
+
{{{
31 -
To add a footnote to text you use the footnote macro. [[FootNote(Footnotes are automatically linked)]] You use the same macro but with no text to display the accumulated list of footnotes. For example:
+
To add a footnote to text you use the footnote macro. [[FootNote(Footnotes are automatically linked)]] You use the same macro but with no text to display the accumulated list of footnotes. For example:
32 -
 
+
33 -
[[FootNote]]
+
[[FootNote]]
34 -
}}}
+
}}}
35 -
 
+
36 -
Display:
+
Display:
37 -
To add a footnote to text you use the footnote macro. [[FootNote(Footnotes are automatically linked)]] You use the same macro but with no text to display the accumulated list of footnotes. For example:
+
To add a footnote to text you use the footnote macro. [[FootNote(Footnotes are automatically linked)]] You use the same macro but with no text to display the accumulated list of footnotes. For example:
38 -
 
+
39 -
[[FootNote]]
+
[[FootNote]]
40 -
 
+
41 -
== Available Macros ==
+
== Available Macros ==
42 -
`[[BR]]`::
+
43 -
Insert a line break.
+
[[MacroList()]]
44 -
`[[Span(content, attributes)]]`::
+
45 -
Wraps text or other elements inside a `<span>` tag.
+
46 -
`[[Image(filename)]]`::
+
47 -
Embed an image in wiki-formatted text. The first argument is the filename of the image. The remaining arguments are optional and allow configuring the attributes and style of the rendered `<img>` element:{{{#!html<ul>
+
48 -
<li>digits and unit are interpreted as the size (ex. 120, 25%) for the image</li>
+
49 -
<li>right, left, top or bottom are interpreted as the alignment for the image</li>
+
50 -
<li>nolink means without link to image source</li>
+
51 -
<li>key=value style are interpreted as HTML attributes or CSS style indications for the image.<br />Valid keys are: align, border, width, height, alt, title, longdesc, class, id and usemap</li>
+
52 -
</ul>}}}
+
53 -
`[[File(content, attributes)]]`::
+
54 -
Works similar to the Image macro but, instead, generates a link to a file. The first argument is the filename.
+
55 -
`[[Resource(id,alias)]]`::
+
56 -
This macro will insert a linked title to a resource. It can be passed wither an ID or alias.
+
57 -
`[[Tool(id,alias)]]`::
+
58 -
This macro functions identically to the Resource macro mentioned above.
+
59 -
`[[Contributor(id,username,name)]`::
+
60 -
This macro will generate a link to a contributor's page with the contributor's name as the link text. It accepts either the contributor's ID, username, or name. NOTE: to use a name, it must be identical to their contributor page.
+
61 -
`[[Tag(tag)]]`::
+
62 -
This macro will generate a link to a Tag.
+
63 -
`[[TitleIndex(prefix)]]`::
+
64 -
Inserts an alphabetic list of all wiki pages into the output. Accepts a prefix string as parameter: if provided, only pages with names that start with the prefix are included in the resulting list. If this parameter is omitted, all pages are listed.
+
65 -
`[[FootNote(footnote text)]]`::
+
66 -
Add a footnote, or explicitly display collected footnotes when no args (footnote text) are given.
+
67 -
`[[RandomPage]]`::
+
68 -
Generates a link to a random page.
+
69 -
`[[Anchor(anchorname)]]`::
+
70 -
Inserts an anchor into a page.
+