Template:Electiontable: Difference between revisions

From MicrasWiki
Jump to navigationJump to search
No edit summary
Test
 
(2 intermediate revisions by one other user not shown)
Line 1: Line 1:
<noinclude>
{| class="wikitable {{#if:{{{collapsed|}}}|mw-collapsible mw-collapsed}} {{#ifeq:{{{sortable|}}}|yes|sortable}}" style="text-align:right; font-size: 95%; {{#switch:{{lc:{{{align|}}}}}|=|none=|left=float:{{{align}}};margin-right:1em;|right=float:{{{align}}};margin-left:1em;|center|centre=margin-left:auto; margin-right:auto;|#default= }}"
==Usage==
{{#if:{{{collapsed|}}}|! colspan=12 style="text-align:center; font-weight:normal;" {{!}}|{{!}}+}} {{#if:{{{template_name|{{{1|}}}}}}|<span style="float:left; align:left; font-size: 90%;" class="editlink noprint plainlinks nourlexpansion">[{{fullurl:{{transclude|{{{template_name|{{{1|}}}}}}}}|action=edit}} e]&nbsp;•&nbsp;[[{{TALKPAGENAME:{{transclude|{{{template_name|{{{1|}}}}}}}}}}|d]]</span>&nbsp;|}}{{#if:{{{title|{{{2|}}}}}}|{{{title|{{{2}}}}}}}}<!--
This template marks the beginning of a table and defines borders, margins, background colours, and text alignment within the table. (Default alignment is "right" - for numbers, others must be specified.) Table rows and cells are written as usual in any number and the table is closed with "<code><nowiki>|}</nowiki></code>"
--><noinclude>
 
Example:
 
{{electiontable|Table template pagename}}'''Summary of [[Mars]]ian election results, [[2005]]'''
|-style="background:#E9E9E9;"
! align="left"|Parties
! Votes
! %
! +/-
! Seats
! +/-
|-
| align="left"|The Little Green Party
| 123,456
| 79.2
| -8.3
| 53
| -8
|-
| align="left"|The Red Party
| 23,697
| 15.2
| +6.6
| 10
| +4
|-
| align="left"|The Sun-Followers' Party
| 8,730
| 5.6
| +1.7
| 4
| +4
|-style="background:#E9E9E9;"
! align="left"|Total
! 155,883
! align="center" colspan="2"|100%
! align="center" colspan="2"|67
|}
|}
[[Category: Politics templates]]</noinclude> {| border="1" cellpadding="4" cellspacing="1" style="margin: 1em 1em 1em 0; background: #f9f9f9; border: 1px #aaa solid; text-align:right; border-collapse: collapse; font-size: 95%;"
[[Category:Politics templates]]</noinclude>
|+

Latest revision as of 15:29, 2 March 2023