cogAdds a link to download an attachment in the wiki
Typeradeoxmacro
Developed by

XWiki Development Team

Rating
Rate!
0 Votes
LicenseGNU Lesser General Public License 2.1

Description

Can also link to an external resource.

For XWiki Syntax 2.0, use the syntax directly. For example: attach:myimage.png. See the Syntax Page for more details.

Usage

{attach:<link text>|file=<file>|document=<document>|title=<title>|rel=<rel>|id=<id>|fromIncludingDoc=}

Parameters definition

NameOptionalAllowed valuesDefault valuesDescription
link text staryesTextIf missing, the file name is used.The link text.
file staryesattachment name or an absolute urlIf missing, the link text is used.The target filename.
document (**)yesdocument name within the wikicurrent documentThe document to which the file is attached (allows linking to files attached to different pages).
titleyesTextIf missing, no title.The title attribute of the link. Often rendered as a tooltip.
relyesLink TypesIf missing, no rel.The rel attribute of the link. Specifies the relation from this document to the link.
idyes If missing, no id.The id attribute of the link.
fromIncludingDoc (**)yesEmpty(just end with =) Fetch the attachment from the parent document that included the current document. This is useful for templates, for example.

star 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

A simple text file \  An image file on another page \

Tags: obsolete
Created by melvng on 2007/02/12 22:43
    

Get Connected