Template:Link if not current: Difference between revisions
Template page
More actions
Created page with "{{#ifeq:{{{1}}}|{{PAGENAME}}|| *[[{{{1}}}|{{#if:{{{2|}}}|{{{2}}}|{{{1}}}}}]]}}<noinclude> {{documentation}} </noinclude>" |
(No difference)
|
Latest revision as of 01:30, 18 February 2025
- [[{{{1}}}|{{{1}}}]]
Use this template to avoid producing a self link.
Usage
{{Link if not current|Article}}
produces
- a list item linking to Article if the current page's title is not
Article
, - nothing if it is.
Parameters
- Parameter 1 is necessary, as it is the link.
- Parameter 2 is optional, and it is the text that is displayed over the link. If parameter 2 doesn't exist, it defaults to parameter 1.
See also
- {{Template:No self link}} – always outputs the text (either linked or not) and NOT embedded in a list item
- {{Link if exists}}