Attach Macro (Radeox)
Last modified by Thomas Mortagne on 2023/10/10 14:24
Adds a link to download an attachment in the wiki.
Can also link to an external resource.
Usage
{attach:<link text>|file=<file>|document=<document>|title=<title>|rel=<rel>|id=<id>|fromIncludingDoc=}
Parameters definition
Name | Optional | Allowed values | Default values | Description |
---|---|---|---|---|
link text | yes | Text | If missing, the file name is used. | The link text. |
file | yes | attachment name or an absolute url | If missing, the link text is used. | The target filename. |
document (**) | yes | document name within the wiki | current document | The document to which the file is attached (allows linking to files attached to different pages). |
title | yes | Text | If missing, no title. | The title attribute of the link. Often rendered as a tooltip. |
rel | yes | Link Types | If missing, no rel. | The rel attribute of the link. Specifies the relation from this document to the link. |
id | yes | If missing, no id. | The id attribute of the link. | |
fromIncludingDoc (**) | yes | Empty(just end with =) | Fetch the attachment from the parent document that included the current document. This is useful for templates, for example. |
At least one of these parameters must be specified. Macro is ignored if both are missing.
(**) Use either document or fromIncludingDoc. Parameter fromIncludingDoc is ignored if both are specified.
Example
{attach:A simple text file|file=simple.txt|title=Download Simple Txt}
{attach: An image file on another page|file=gamesigns.jpg|document=ImageMacro|title=Download gamesigns.jpg}
Result
\ \