Open main menu

Changes

1,136 bytes added ,  13:58, 15 January 2016
Created page with "{{Documentation subpage}} <!--PLEASE ADD CATEGORIES AT THE END OF THIS PAGE.---> A simple template to center-align content in tables and other places. == Example == {{markup..."
{{Documentation subpage}}
<!--PLEASE ADD CATEGORIES AT THE END OF THIS PAGE.--->
A simple template to center-align content in tables and other places.

== Example ==
{{markup
| <nowiki>{{Center|Hello world!}}</nowiki>
| {{Center|Hello world!}}
}}

To do this without a template, simply use the following code:
:{{tag|div|params=class="center" style="width:auto; margin-left:auto; margin-right:auto;"}}

To center a table, see [[Help:TABLECENTER]].

=== Table ===
Using {{tld|left}} / {{tld|center}} / {{tld|right}}
{| class="wikitable"
!colspan="3" style="width:300px"| Header text
|-
| {{Left|Left}} || {{Center|Center}} || {{Right|Right}}
|}
Using {{tld|align|left}} / {{tld|align|center}} / {{tld|align|right}}
{| class="wikitable"
!colspan="3" style="width:300px"| Header text
|-
| {{align|left|Left}} || {{align|center|Center}} || {{align|right|Right}}
|}

== See also ==
*{{tl|Align}}
*{{tl|Left}}
*{{tl|Right}}

<includeonly>{{basepage subpage
| <!---CATEGORIES BELOW THIS LINE, PLEASE:--->
[[Category:Positioning templates]]
[[Category:Typing-aid templates]]
[[Category:Wikipedia XHTML tag-replacing templates]]
}}</includeonly>
4,558

edits