| Link Attributes
Release status: stable
|Description||Extends the link syntax to allow custom attributes, such as rel="author"|
|Author(s)||Leo Wallentin, Stano Lacko, Sincerly|
|Latest version||0.4 (2022-06-16)|
|License||BSD 3-clause "Modified" License|
The LinkAttributes extension extends the link syntax to allow custom attributes, such as rel="author".
Extra attributes are added at the end of a link, separated with a pipe (|) or a broken pipe (¦), like this:
[http://www.twitter.com/me my Twitter account|rel=me]
Allowed properties are:
In some places (such as inside templates with tables) the pipe can be hard to use, as it has special meanings to MediaWiki. Therefore a broken pipe (¦) will also work with this extension:
Oranges¦itemprop=fruit. Note that the following will NOT add an attribute:
[[User:James|rel=author]]. The extension has no way of knowing if
rel=author is supposed to be an attribute or the actual text to be linked, so the link would have to be written like this:
[[User:James|James|rel=author]]. Also note that after installing this extension, pipe characters will not work in link texts.
itemscope is HTML attribute without value, link have to be written like this:
- Download and place the file(s) in a directory called
- Add the following code at the bottom of your
- Done – Navigate to Special:Version on your wiki to verify that the extension is successfully installed.