Link – Template
Lou Montana (talk | contribs) m (Add example) |
Lou Montana (talk | contribs) (Add mailto protocol support) |
||
Line 1: | Line 1: | ||
<includeonly>{{#if:{{{link|{{{1|}}}}}} | <includeonly>{{#if:{{{link|{{{1|}}}}}} | ||
| {{#if:{{#pos:{{{link|{{{1|}}}}}}|<nowiki/>://}} | | {{#if:{{#pos:{{{link|{{{1|}}}}}}|<nowiki/>://}}{{#pos:{{{link|{{{1|}}}}}}|mailto:}} | ||
| {{Link/External|link= {{{link|{{{1}}}}}}|text= {{{text|{{{2|}}}}}}}} | | {{Link/External|link= {{{link|{{{1}}}}}}|text= {{{text|{{{2|}}}}}}}} | ||
| {{Link/Internal|link= {{{link|{{{1}}}}}}|text= {{{text|{{{2|}}}}}}}} | | {{Link/Internal|link= {{{link|{{{1}}}}}}|text= {{{text|{{{2|}}}}}}}} | ||
Line 49: | Line 49: | ||
<nowiki>{{Link|Template:Messagebox|Messagebox Template}}</nowiki><br> | <nowiki>{{Link|Template:Messagebox|Messagebox Template}}</nowiki><br> | ||
<nowiki>{{Link|Template:Messagebox#Usage}}</nowiki><br> | <nowiki>{{Link|Template:Messagebox#Usage}}</nowiki><br> | ||
<nowiki>{{Link|Template:Messagebox#Usage|Messagebox template usage}}</nowiki> | <nowiki>{{Link|Template:Messagebox#Usage|Messagebox template usage}}</nowiki><br> | ||
|result7= {{Link|setDir}}<br>{{Link|Arma Reforger:Getting Started}}<br>{{Link|Template:Messagebox}}<br>{{Link|Template:Messagebox|Messagebox Template}}<br>{{Link|Template:Messagebox#Usage}}<br>{{Link|Template:Messagebox#Usage|Messagebox template usage}} | <nowiki>{{Link|mailto:support@example.com|support e-mail}}</nowiki> | ||
|result7= {{Link|setDir}}<br>{{Link|Arma Reforger:Getting Started}}<br>{{Link|Template:Messagebox}}<br>{{Link|Template:Messagebox|Messagebox Template}}<br>{{Link|Template:Messagebox#Usage}}<br>{{Link|Template:Messagebox#Usage|Messagebox template usage}}<br>{{Link|mailto:support@example.com|support e-mail}} | |||
}}</noinclude> | }}</noinclude> |
Revision as of 17:04, 3 July 2024
This template combines {{Link/External}} and {{Link/Internal}} under one entrypoint. It also adds the page to the Link template usage error category on usage error.
This template is used on these pages.
Usage
{{Link|link|text}}
- link: (possibly named parameter) the URL or the local link, hashed or not (Operation Flashpoint#Introduction)
- text: (Optional, possibly named parameter) text to be displayed
Code | Result |
---|---|
{{Link}} | -no link provided- |
{{Link|http://}} | http:// |
{{Link|link= http://ofp.gamepark.cz/index.php?showthis=2302}} | ofpr.info link link courtesy of OFP-Faguss.com |
{{Link|setDir}} |
setDir setDir - notes setDir and nothing else |
{{Link|#}} |
[[#|]] Usage The Usage chapter |
{{Link|Arma Reforger:Getting Started}} |
Arma Reforger:Getting Started Test Arma Reforger:Getting Started - Play in Single Player Play in Single Player |
{{Link|setDir}} |
setDir Arma Reforger:Getting Started Messagebox Messagebox Template Messagebox - Usage Messagebox template usage support e-mail |