Difference between revisions of "Template:Rml"

From railML 3 Wiki
Jump to: navigation, search
(Option ohne Link)
Line 1: Line 1:
<includeonly>{{#vardefine:space|{{#if:{{{1|}}}|&#32;}}}}{{#ifeq:{{#sub:{{{1}}}|0|1}}|2|{{wiki2||railML<sup><small>®</small></sup>&#32;{{{1|}}}}}|railML<sup><small>®</small></sup>{{#var:space}}{{{1|}}}}}</includeonly><noinclude>
+
<includeonly>{{#vardefine:display|railML<sup><small>®</small></sup>{{{1|}}}}}{{#ifeq:{{#sub:{{{1}}}|0|1}}|2|{{#vardefine:display|[https://wiki2.railml.org railML<sup><small>®</small></sup>{{{1|}}}]}}}}{{#ifeq:{{{link}}}|no|{{#vardefine:display|railML<sup><small>®</small></sup>{{{1|}}}}}}}{{#var:display}}</includeonly><noinclude>
 
==Usage==
 
==Usage==
This template is intended to allow for a standardized and adaptable display of the brand name railML<sup>®</sup>.
+
This template is intended to allow for a standardized and adaptable display of the brand name railML<sup>®</sup>. If it refers to {{rml|2}} it will produce a link.
 
===Arguments===
 
===Arguments===
This template has no arguments.
+
*1 (optional): a version number
 +
*link (optional): if "no", no link will be produced; default: "yes"
 
===Dependencies===
 
===Dependencies===
 
This template does not use or serve any other templates.
 
This template does not use or serve any other templates.
  
 
==Example==
 
==Example==
<nowiki>{{rml}}</nowiki>
+
<pre>{{rml}}</pre>
  
 
delivers
 
delivers
  
 
{{rml}}
 
{{rml}}
 
+
<pre>{{rml|2.4}}</pre>
<nowiki>{{rml|2.4}}</nowiki>
 
  
 
delivers
 
delivers
  
 
{{rml|2.4}}
 
{{rml|2.4}}
 
+
<pre>{{rml|3.1}}</pre>
<nowiki>{{rml|3.1}}</nowiki>
 
  
 
delivers
 
delivers
  
 
{{rml|3.1}}
 
{{rml|3.1}}
 +
<pre>{{rml|2.5|link=no}}</pre>delivers:
 +
 +
{{rml|2.5|link=no}}
  
 
{{interwiki}}
 
{{interwiki}}
 
 
[[Category:ContentTemplate]]</noinclude>
 
[[Category:ContentTemplate]]</noinclude>

Revision as of 16:53, 20 August 2021

Usage

This template is intended to allow for a standardized and adaptable display of the brand name railML®. If it refers to railML® 2 it will produce a link.

Arguments

  • 1 (optional): a version number
  • link (optional): if "no", no link will be produced; default: "yes"

Dependencies

This template does not use or serve any other templates.

Example

{{rml}}

delivers

railML®

{{rml|2.4}}

delivers

railML® 2.4

{{rml|3.1}}

delivers

railML® 3.1

{{rml|2.5|link=no}}

delivers:

railML® 2.5