Template:Sandbox: Difference between revisions

From Crazy-Fools.co.uk Wiki
No edit summary
No edit summary
 
(3 intermediate revisions by the same user not shown)
Line 22: Line 22:
this draws a line to show where the template description ends and the template itself starts. The template would work without it.  
this draws a line to show where the template description ends and the template itself starts. The template would work without it.  
-->
-->
</noinclude>


<templatedata>
<templatedata>
Line 29: Line 27:
"description": "A simple template that requires two values, first value and second value",
"description": "A simple template that requires two values, first value and second value",
"params": {
"params": {
"First Value": {
"firstValue": {
"aliases": [
"firstValue"
],
"label": "The First Value",
"label": "The First Value",
"type": "string",
"type": "string",
"required": true
"required": true
},
},
"The Second Value": {
"secondValue": {
"aliases": [
"secondValue"
],
"label": "Second Value",
"label": "Second Value",
"description": {
"en": "Timestamp of when the comment was posted, in YYYY-MM-DD format."
},
"type": "string",
"type": "string",
"required": true
"required": true
Line 50: Line 39:
},
},
"paramOrder": [
"paramOrder": [
"First Value",
"firstValue",
"The Second Value"
"secondValue"
]
]
}
}
</templatedata>
</templatedata>


</noinclude>


{| class="wikitable" border="1" style="float:right; width:33%" <!-- float puts it on right side and wraps text -->
{| class="wikitable" border="1" style="float:right; width:33%" <!-- float puts it on right side and wraps text -->

Latest revision as of 20:22, 31 May 2024


Look at this in source or edit view to really see how it is set up.

This template just demonstrates a really simple infobox that will show up at the right top of where the template is used. It is really just a mediawiki template that generates a right floating mediawiki table.

Template Use

To use this template, put the following text on a page, replacing the values as instructed.

{{SampleInfobox
| firstValue = replace this with first value
| secondValue = replace this with second value
}}


A simple template that requires two values, first value and second value

Template parameters[Edit template data]

ParameterDescriptionTypeStatus
The First ValuefirstValue

no description

Stringrequired
Second ValuesecondValue

no description

Stringrequired


A Sample Infobox
First Value: {{{firstValue}}}
Second Value: {{{secondValue}}}