No edit summary |
No edit summary |
||
| Line 1: | Line 1: | ||
{{Documentation}} | {{Documentation}} | ||
<includeonly><onlyinclude><div><div class="box {{{color|red}}}"><div class="overbox {{{color|red}}}">{{ | <includeonly><onlyinclude><div><div class="box {{{color|red}}}"><div class="overbox {{{color|red}}}">{{{1|{{Error|{{Template|Box}} has mandatory parameters}}}</div>{{{2|{{Lorem Ipsum}}}}}</div></div></onlyinclude></includeonly> | ||
Revision as of 16:37, 14 October 2022
Template:Box is used to create formatted text boxes.
Usage
It accepts one mandatory string parameter and one optional string parameter.
1is the name of the article and the header for the text box.2, if supplied, is the contents of the text box. If not supplied, the contents is transcluded from a subpage of the article, using the header as the subpage name. It also usesTemplate:Editto adds a link to directly edit the subpage.
It also accepts two optional named parameters:
widthacceptsXpxorX%, and controls the width of the box. If undefined, the box has10%margins left and right.floatacceptsleft,right, orclear.- If
leftorright, the box is floated to the selected side of the screen and the margins and padding are setup coorespondingly. - If
clear, the box is arranged clear of all content, above and below.
- If
color(default:blue) controls the color of the background. The valid options are:
red
green
blue
yellow
purple
cyan
gray
white
Return
{{{Box|color=green|Lorem Ipsum|{{Lorem Ipsum|2}}}} returns: {{{1|Error!
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Duis quis metus nunc. Fusce est libero, interdum vel iaculis et, blandit quis odio. Integer ac magna nunc. In quis libero purus. Praesent mattis eget justo in efficitur. Aenean tempor congue dictum. Mauris hendrerit nunc a auctor dictum. Template:Box has mandatory parameters!}{{Box|Sample}} returns: {{{1|Error!
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Duis quis metus nunc. Fusce est libero, interdum vel iaculis et, blandit quis odio. Integer ac magna nunc. In quis libero purus. Praesent mattis eget justo in efficitur. Aenean tempor congue dictum. Mauris hendrerit nunc a auctor dictum. Maecenas auctor eu urna blandit lobortis. Aenean maximus ante vel pretium congue. Sed et turpis vel ipsum condimentum laoreet sit amet vel nisi. Nulla non vulputate arcu, sit amet pellentesque elit. Pellentesque ac tortor viverra, finibus est ac, varius urna. Donec sagittis, elit sit amet sagittis tempor, nibh arcu blandit magna, ut aliquam metus lacus non ligula. Vivamus et ligula quis magna luctus imperdiet.Template:Box has mandatory parameters!}float, as they don't appear correctly inside Template:Return.
The documentation above was transcluded from Template:Box/Documentation. [edit]
