Template:Linkifexists: Difference between revisions
Jump to navigation
Jump to search
imported>Sekoia (historical) (Created page with "{{#ifexist:{{{page|{{{1}}}}}}|[[{{{page|{{{1}}}}}}|{{{name|{{{2|{{{1}}}}}}}}}]]|{{{name|{{{2|{{{1}}}}}}}}}}}<noinclude>{{documentation}}</noinclude>") |
imported>Sekoia (historical) m (moved Linkifexists to Template:Linkifexists: Oops) |
(No difference)
|
Revision as of 06:12, 29 June 2012
{{{1}}}
[edit] [ ] Documentation
Usage
This will link to a page if the target exists. Otherwise, it will just display the name without a link. There are several ways to call it:
{{linkifexists|Page Name}}
{{linkifexists|Page Name|Display Name}}
{{linkifexists|page=Page Name}}
{{linkifexists|page=Page Name|name=Display Name}}
Examples
Target Exists | Target Doesn't Exist | ||
---|---|---|---|
Template Call | Result | Template Call | Result |
{{linkifexists|Main Page}}
|
Main Page | {{linkifexists|Fake Page}}
|
Fake Page |
{{linkifexists|Main Page|Home}}
|
Home | {{linkifexists|Fake Page|Home}}
|
Home |
{{linkifexists|page=Main Page}}
|
{{{1}}} | {{linkifexists|page=Fake Page}}
|
{{{1}}} |
{{linkifexists|page=Main Page|name=Home}}
|
Home | {{linkifexists|page=Fake Page|name=Home}}
|
Home |