Template:Relative link/doc
![]() | This is a documentation subpage for Template:Relative link. It may contain usage information, categories and other content that is not part of the original template page. |
![]() | This template may be substituted. |
__EXPECTUNUSEDTEMPLATE__
![]() | This template uses Lua: |
The {{Relative link}} and {{Relative link implicit}} templates facilitate linking subpages and parent pages. If a link is not a subpage or a parent page of the current page the template simply creates a regular link.
Usage
Note: The
..
identifier is supported too (e.g. <syntaxhighlight lang="wikitext" inline>../example</syntaxhighlight>).
{{Relative link}}
- <syntaxhighlight lang="wikitext" inline>./example</syntaxhighlight>
- <syntaxhighlight lang="wikitext" inline>../example</syntaxhighlight>
- <syntaxhighlight lang="wikitext" inline>Wikipedia:Lua</syntaxhighlight>
- <syntaxhighlight lang="wikitext" inline>.</syntaxhighlight>
- ↳ .
- <syntaxhighlight lang="wikitext" inline>.</syntaxhighlight>
- ↳ .
{{Relative link implicit}}
(Same as {{Relative link}}, but omitting possible initial dots)
- <syntaxhighlight lang="wikitext" inline>example</syntaxhighlight>
- ↳ example
- <syntaxhighlight lang="wikitext" inline>Template:Relative link implicit/example</syntaxhighlight>
- <syntaxhighlight lang="wikitext" inline>Wikipedia:Lua</syntaxhighlight>
- <syntaxhighlight lang="wikitext" inline>Relative link/doc</syntaxhighlight>
- <syntaxhighlight lang="wikitext" inline>Relative link/doc</syntaxhighlight>
See also
- {{#invoke:path|rel}} and {{#invoke:path|sub}}
- Category:Internal link templates