Jump to content

Template talk:Election table: Difference between revisions

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia
Content deleted Content added
Add sticky-header option: sandbox version to test
Line 217: Line 217:
: This places the template {{tl|sticky-header}} before the table, but I think this can introduce a spurious blank line when the sticky parameter isn't used. I'll use this example on this page to test a way around this. &nbsp;—&nbsp;<span style="white-space: nowrap;font-family:Arial;background:#d6ffe6;border:solid 1px;border-radius:5px;box-shadow:darkcyan 0px 1px 1px;"> [[User:Jts1882|Jts1882]] &#124;[[User talk:Jts1882| talk]]&nbsp;</span> 16:18, 5 July 2024 (UTC)
: This places the template {{tl|sticky-header}} before the table, but I think this can introduce a spurious blank line when the sticky parameter isn't used. I'll use this example on this page to test a way around this. &nbsp;—&nbsp;<span style="white-space: nowrap;font-family:Arial;background:#d6ffe6;border:solid 1px;border-radius:5px;box-shadow:darkcyan 0px 1px 1px;"> [[User:Jts1882|Jts1882]] &#124;[[User talk:Jts1882| talk]]&nbsp;</span> 16:18, 5 July 2024 (UTC)
:: {{ping|cmglee}} The sandbox version seems to work. Can you test it on the example table you want to use it on or give me the page here? &nbsp;—&nbsp;<span style="white-space: nowrap;font-family:Arial;background:#d6ffe6;border:solid 1px;border-radius:5px;box-shadow:darkcyan 0px 1px 1px;"> [[User:Jts1882|Jts1882]] &#124;[[User talk:Jts1882| talk]]&nbsp;</span> 16:44, 5 July 2024 (UTC)
:: {{ping|cmglee}} The sandbox version seems to work. Can you test it on the example table you want to use it on or give me the page here? &nbsp;—&nbsp;<span style="white-space: nowrap;font-family:Arial;background:#d6ffe6;border:solid 1px;border-radius:5px;box-shadow:darkcyan 0px 1px 1px;"> [[User:Jts1882|Jts1882]] &#124;[[User talk:Jts1882| talk]]&nbsp;</span> 16:44, 5 July 2024 (UTC)

::: {{ping|Jts1882}} Thank you so much for the quick response. I wish to use it on [[Template:2024_United_Kingdom_parliamentary_election]] and reproducing it below, it's perfect except that the sticky header did not include the second row of the header. I'm unsure what the best solution is. Cheers, '''[[User:cmglee|cm&#610;&#671;ee]]'''&#9094;[[User_Talk:cmglee|&#964;a&#671;&#954;]] 17:47, 5 July 2024 (UTC)
{{election table/sandbox|2024 United Kingdom parliamentary election|Results of the July 2024 general election to the [[House of Commons of the United Kingdom]] (649 of 650 seats declared)|sticky-header=yes|sortable=yes}}
<!-- Use minuses, not hyphens; em dashes; or en dashes, as these are wrong and helpfully break sorting. -->
|- style="text-align:center; background-color:#F2F2F2;"
!scope="colgroup" style="border: 1px solid #aaa;" colspan=2 rowspan=2 | Political party
!scope="col" style="border: 1px solid #aaa;" rowspan=2 | Leader
!scope="col" style="border: 1px solid #aaa;" rowspan=2 | [[Candidates in the 2024 United Kingdom general election|Candidates]]
!scope="col" style="border: 1px solid #aaa;" colspan=5 | MPs
!scope="col" style="border: 1px solid #aaa;" colspan=3 | Aggregate votes
|- style="text-align:center; background-color:#F2F2F2;"
!scope="col" style="border: 1px solid #aaa;" | Total
!scope="col" style="border: 1px solid #aaa;" | Gained {{efn|Notional Gains in accordance with [[2023 Periodic Review of Westminster constituencies Notional 2019 general election results|Thrasher and Railings calculations]]}}
!scope="col" style="border: 1px solid #aaa;" | Lost {{efn|Notional Losses in accordance with [[2023 Periodic Review of Westminster constituencies Notional 2019 general election results|Thrasher and Railings calculations]]}}
!scope="col" style="border: 1px solid #aaa;" | Net
!scope="col" style="border: 1px solid #aaa;" | Of total<br/>(%)
!scope="col" style="border: 1px solid #aaa;" | Total
!scope="col" style="border: 1px solid #aaa;" | Of total<br/>(%)
!scope="col" style="border: 1px solid #aaa;" | Change<br/>(%)
|-
!scope="row" data-sort-value="Labour Party (UK)" {{Party color cell|Labour Party (UK)}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | {{party shortname linked|Labour Party (UK)}}
| style="border: 1px solid #aaa; text-align: left;" | {{sortname|Keir|Starmer}}
| style="border: 1px solid #aaa;" | 631
| style="border: 1px solid #aaa;" | 411
| style="border: 1px solid #aaa;" | 220
| style="border: 1px solid #aaa;" | 6
| style="border: 1px solid #aaa;" | {{increase}} 214
| style="border: 1px solid #aaa;" | 63.2
| style="border: 1px solid #aaa;" | 9,698,409
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="Conservative Party (UK)" {{Party color cell|Conservative Party (UK)}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | {{party shortname linked|Conservative Party (UK)}}
| style="border: 1px solid #aaa; text-align: left;" | {{sortname|Rishi|Sunak}}
| style="border: 1px solid #aaa;" | 635
| style="border: 1px solid #aaa;" | 121
| style="border: 1px solid #aaa;" | 1
| style="border: 1px solid #aaa;" | 252
| style="border: 1px solid #aaa;" | {{decrease}} 251
| style="border: 1px solid #aaa;" | 18.6
| style="border: 1px solid #aaa;" | 6,824,809
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="Liberal Democrats (UK)" {{Party color cell|Liberal Democrats (UK)}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | {{party shortname linked|Liberal Democrats (UK)}}
| style="border: 1px solid #aaa; text-align: left;" | {{sortname|Ed|Davey}}
| style="border: 1px solid #aaa;" | 630
| style="border: 1px solid #aaa;" | 71
| style="border: 1px solid #aaa;" | 63
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{increase}} 63
| style="border: 1px solid #aaa;" | 10.9
| style="border: 1px solid #aaa;" | 3,501,040
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="Scottish National Party" {{Party color cell|Scottish National Party}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Scottish National Party]]
| style="border: 1px solid #aaa; text-align: left;" | {{sortname|John|Swinney}}
| style="border: 1px solid #aaa;" | 57
| style="border: 1px solid #aaa;" | 9
| style="border: 1px solid #aaa;" | 1
| style="border: 1px solid #aaa;" | 39
| style="border: 1px solid #aaa;" | {{decrease}} 38
| style="border: 1px solid #aaa;" | 1.4
| style="border: 1px solid #aaa;" | 708,759
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="Sinn Féin" {{Party color cell|Sinn Féin}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Sinn Féin]]
| style="border: 1px solid #aaa; text-align: left;" | {{sortname|Mary Lou|McDonald}}
| style="border: 1px solid #aaa;" | 14
| style="border: 1px solid #aaa;" | 7
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 1.1
| style="border: 1px solid #aaa;" | 210,891
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="Independent" {{Party color cell|Independent}}
|scope="row" style="border: 1px solid #aaa; text-align: left;" | Independents
| {{N/A}}
| style="border: 1px solid #aaa;" | 459
| style="border: 1px solid #aaa;" | 6
| style="border: 1px solid #aaa;" | 6
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{increase}} 6
| style="border: 1px solid #aaa;" | 0.8
| style="border: 1px solid #aaa;" | 564,243
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="Reform UK" {{Party color cell|Reform UK}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | {{party shortname linked|Reform UK}}
| style="border: 1px solid #aaa; text-align: left;" | {{sortname|Nigel|Farage}}
| style="border: 1px solid #aaa;" | 609
| style="border: 1px solid #aaa;" | 5
| style="border: 1px solid #aaa;" | 5
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{increase}} 5
| style="border: 1px solid #aaa;" | 0.6
| style="border: 1px solid #aaa;" | 4,114,287
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="Democratic Unionist Party" {{Party color cell|Democratic Unionist Party}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" |[[Democratic Unionist Party|Democratic Unionist]]
| style="border: 1px solid #aaa; text-align: left;" | {{sortname|Gavin|Robinson}}
| style="border: 1px solid #aaa;" | 16
| style="border: 1px solid #aaa;" | 5
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 3
| style="border: 1px solid #aaa;" | {{decrease}} 3
| style="border: 1px solid #aaa;" | 0.8
| style="border: 1px solid #aaa;" | 172,058
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="Green Party of England and Wales" {{Party color cell|Green Party of England and Wales}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Green Party of England and Wales|Green (England & Wales)]]
| style="border: 1px solid #aaa; text-align: left;" | {{sortname|Carla|Denyer}} & {{sortname|Adrian|Ramsay}}
| style="border: 1px solid #aaa;" | 574
| style="border: 1px solid #aaa;" | 4
| style="border: 1px solid #aaa;" | 3
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{increase}} 3
| style="border: 1px solid #aaa;" | 0.6
| style="border: 1px solid #aaa;" | 1,841,888
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Plaid Cymru}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Plaid Cymru]]
| style="border: 1px solid #aaa; text-align: left;" | {{sortname|Rhun|ap Iorwerth}}
| style="border: 1px solid #aaa;" | 32
| style="border: 1px solid #aaa;" | 4
| style="border: 1px solid #aaa;" | 2
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}} {{efn|Plaid Cymru won 4 seats at the last election, but only 2 in accordance with [[2023 Periodic Review of Westminster constituencies Notional 2019 general election results|the notional results of new boundaries]]}}
| style="border: 1px solid #aaa;" | 0.6
| style="border: 1px solid #aaa;" | 194,811
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Social Democratic and Labour Party}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Social Democratic and Labour Party|Social Democratic & Labour]]
| style="border: 1px solid #aaa; text-align: left;" | {{sortname|Colum|Eastwood}}
| style="border: 1px solid #aaa;" | 18
| style="border: 1px solid #aaa;" | 2
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.3
| style="border: 1px solid #aaa;" | 86,861
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Alliance Party of Northern Ireland}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | {{party shortname linked|Alliance Party of Northern Ireland}}
| style="border: 1px solid #aaa; text-align: left;" | {{sortname|Naomi|Long}}
| style="border: 1px solid #aaa;" | 18
| style="border: 1px solid #aaa;" | 1
| style="border: 1px solid #aaa;" | 1
| style="border: 1px solid #aaa;" | 1
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.2
| style="border: 1px solid #aaa;" | 117,191
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Ulster Unionist Party}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" |[[Ulster Unionist Party|Ulster Unionist]]
| style="border: 1px solid #aaa; text-align: left;" | {{sortname|Doug|Beattie}}
| style="border: 1px solid #aaa;" | 17
| style="border: 1px solid #aaa;" | 1
| style="border: 1px solid #aaa;" | 1
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{increase}} 1
| style="border: 1px solid #aaa;" | 0.2
| style="border: 1px solid #aaa;" | 94,779
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Traditional Unionist Voice}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Traditional Unionist Voice]]
| style="border: 1px solid #aaa; text-align: left;" | {{sortname|Jim|Allister}}
| style="border: 1px solid #aaa;" |14
| style="border: 1px solid #aaa;" | 1
| style="border: 1px solid #aaa;" text align=center colspan=3 | ''New''
| style="border: 1px solid #aaa;" | 0.1
| style="border: 1px solid #aaa;" | 48,685
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" | ''New''
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Speaker of the House of Commons (United Kingdom)}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Speaker of the House of Commons (United Kingdom)|Speaker]]
| style="border: 1px solid #aaa; text-align: left;" | [[Lindsay Hoyle]]
| style="border: 1px solid #aaa;" | 1
| style="border: 1px solid #aaa;" | 1
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.1
| style="border: 1px solid #aaa;" | 25,238
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Workers Party of Britain}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | {{party shortname linked|Workers Party of Britain}}
| style="border: 1px solid #aaa; text-align: left;" | {{sortname|George|Galloway}}
| style="border: 1px solid #aaa;" | 152
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 210,194<ref>https://www.bbc.co.uk/news/election/2024/uk/results</ref>
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" | ''New''
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Scottish Greens}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Scottish Greens]]
| style="border: 1px solid #aaa; text-align: left;" | {{sortname|Patrick|Harvie}} & {{sortname|Lorna|Slater}}
| style="border: 1px solid #aaa;" | 44
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 90,647
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Social Democratic Party (UK, 1990–present)}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Social Democratic Party (UK, 1990–present)|Social Democratic Party]]
| style="border: 1px solid #aaa; text-align: left;" |{{sortname|Clouston|William}}
| style="border: 1px solid #aaa;" | 122
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 33,811
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Yorkshire Party}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Yorkshire Party]]
| style="border: 1px solid #aaa; text-align: left;" |Andy Walker
| style="border: 1px solid #aaa;" | 27
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 17,227
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Trade Unionist and Socialist Coalition}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Trade Unionist and Socialist Coalition|Trade Unionist & Socialist]]
| style="border: 1px solid #aaa; text-align: left;" | {{sortname|Dave|Nellist}}
| style="border: 1px solid #aaa;" | 40
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 12,562
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Alba Party}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | {{party shortname linked|Alba Party}}
| style="border: 1px solid #aaa; text-align: left;" | {{sortname|Alex|Salmond}}
| style="border: 1px solid #aaa;" | 19
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 11,784
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Rejoin EU}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Rejoin EU]]
| style="border: 1px solid #aaa; text-align: left;" |Brendan O'Donnelly
| style="border: 1px solid #aaa;" | 26
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 9,245
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Green Party Northern Ireland}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Green Party Northern Ireland|Green Party (NI)]]
| style="border: 1px solid #aaa; text-align: left;" |{{sortname|Mal|O'Hara}}
| style="border: 1px solid #aaa;" | 11
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 8,692
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|People Before Profit}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[People Before Profit]]
| style="border: 1px solid #aaa; text-align: left;" |{{Nowrap|''[[Collective leadership]]''{{Efn|[[Eamonn McCann]] is listed as the party's leader in Northern Ireland for the purposes of registration to the UK [[Electoral Commission (United Kingdom)|Electoral Commission]]. [http://search.electoralcommission.org.uk/English/Registrations/PP773 Electoral Commission registration]|name=|group=}}}}
| style="border: 1px solid #aaa;" | 3
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 8,438
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Aontú}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Aontú]]
| style="border: 1px solid #aaa; text-align: left;" |{{sortname|Peadar|Tóibín}}
| style="border: 1px solid #aaa;" | 10
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 7,466
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Newham Independents Party}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | Newham Independents Party
| style="border: 1px solid #aaa; text-align: left;" | [[Mehmood Mirza]]
| style="border: 1px solid #aaa;" | 1
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 7,180
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Heritage Party (UK)}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Heritage Party (UK)|Heritage Party]]
| style="border: 1px solid #aaa; text-align: left;" | {{sortname|David|Kurten}}
| style="border: 1px solid #aaa;" | 41
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 6,597
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|UK Independence Party}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[UK Independence Party]]
| style="border: 1px solid #aaa; text-align: left;" |Nick Tenconi (interim)
| style="border: 1px solid #aaa;" | 26
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 6,530
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Liberal Party (UK, 1989)}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Liberal Party (UK, 1989)|Liberal Party]]
| style="border: 1px solid #aaa; text-align: left;" |Steve Radford
| style="border: 1px solid #aaa;" | 12
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 6,375
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Ashfield Independents}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Ashfield Independents]]
| style="border: 1px solid #aaa; text-align: left;" | [[Jason Zadrozny]]
| style="border: 1px solid #aaa;" | 1
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 6,276
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Official Monster Raving Loony Party}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Official Monster Raving Loony Party|Monster Raving Loony]]
| style="border: 1px solid #aaa; text-align: left;" |{{sortname|Howling Laud|Hope}}
| style="border: 1px solid #aaa;" | 22
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 5,814
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Christian Peoples Alliance}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Christian Peoples Alliance]]
| style="border: 1px solid #aaa; text-align: left;" |Sidney Cordle
| style="border: 1px solid #aaa;" | 22
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 5,604
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Scottish Family Party}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Scottish Family Party|Scottish Family]]
| style="border: 1px solid #aaa; text-align: left;" |Richard Lucas
| style="border: 1px solid #aaa;" | 16
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 5,425
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|English Democrats}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[English Democrats]]
| style="border: 1px solid #aaa; text-align: left;" |{{sortname|Robin|Tilbrook}}
| style="border: 1px solid #aaa;" | 15
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 5,182
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Party of Women}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Party of Women]]
| style="border: 1px solid #aaa; text-align: left;" |{{sortname|Kellie-Jay|Keen}}
| style="border: 1px solid #aaa;" | 16
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 5,077
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Socialist Labour Party (UK)}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Socialist Labour Party (UK)|Socialist Labour Party]]
| style="border: 1px solid #aaa; text-align: left;" |Jim McDaid
| style="border: 1px solid #aaa;" | 12
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 3,609
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Liverpool Community Independents}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Liverpool Community Independents]]
| style="border: 1px solid #aaa; text-align: left;" |[[Alan Gibbons]]
| style="border: 1px solid #aaa;" | 1
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 3,293
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Swale Independents}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Swale Independents]]
| style="border: 1px solid #aaa; text-align: left;" | Mike Baldock
| style="border: 1px solid #aaa;" | 1
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 3,238
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Hampshire Independents}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Hampshire Independents]]
| style="border: 1px solid #aaa; text-align: left;" | [[Alan Stone (politician)|Alan Stone]]
| style="border: 1px solid #aaa;" | 10
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 2,872
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Communist Party of Britain}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Communist Party of Britain]]
| style="border: 1px solid #aaa; text-align: left;" |{{sortname|Robert|Griffiths|Robert Griffiths (politician)}}
| style="border: 1px solid #aaa;" | 14
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 2,622
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Democracy for Chorley}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | Democracy for Chorley
| style="border: 1px solid #aaa; text-align: left;" |
| style="border: 1px solid #aaa;" | 1
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 2,424
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Independent Oxford Alliance}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | Independent Oxford Alliance
| style="border: 1px solid #aaa; text-align: left;" |
| style="border: 1px solid #aaa;" | 1
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 2,381
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Climate Party}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Climate Party]]
| style="border: 1px solid #aaa; text-align: left;" |Edmund Gemmell
| style="border: 1px solid #aaa;" | 13
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 1,967
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|South Devon Alliance}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | South Devon Alliance
| style="border: 1px solid #aaa; text-align: left;" |
| style="border: 1px solid #aaa;" | 1
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 1,924
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|British Democratic Party (2013)}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[British Democratic Party (2013)|British Democratic Party]]
| style="border: 1px solid #aaa; text-align: left;" | [[Andrew Brons]]
| style="border: 1px solid #aaa;" | 4
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 1,860
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|North East Party}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[North East Party]]
| style="border: 1px solid #aaa; text-align: left;" |Brian Moore
| style="border: 1px solid #aaa;" | 1
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 1,581
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Consensus}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | Consensus
| style="border: 1px solid #aaa; text-align: left;" |
| style="border: 1px solid #aaa;" | 1
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 1,289
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Propel (political party)}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Propel (political party)|Propel]]
| style="border: 1px solid #aaa; text-align: left;" |[[Neil McEvoy]]
| style="border: 1px solid #aaa;" | 1
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 1,041
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Independent Alliance (Kent)}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | Independent Alliance (Kent)
| style="border: 1px solid #aaa; text-align: left;" |
| style="border: 1px solid #aaa;" | 1
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 926
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Portsmouth Independents Party}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Portsmouth Independents Party]]
| style="border: 1px solid #aaa; text-align: left;" |Brian Moore
| style="border: 1px solid #aaa;" | 1
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 733
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Cross-Community Labour Alternative}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Cross-Community Labour Alternative]]
| style="border: 1px solid #aaa; text-align: left;" |Owen McCracken
| style="border: 1px solid #aaa;" | 1
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 624
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Putting Crewe First}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | Putting Crewe First
| style="border: 1px solid #aaa; text-align: left;" |
| style="border: 1px solid #aaa;" | 1
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 588
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
!scope="row" data-sort-value="British National Party" {{Party color cell|Taking the Initiative Party}}
| style="border: 1px solid #aaa; text-align: left;" scope="row" | [[Taking the Initiative Party]]
| style="border: 1px solid #aaa; text-align: left;" |Nicola Zingwari
| style="border: 1px solid #aaa;" | 1
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | 0
| style="border: 1px solid #aaa;" | {{steady}}
| style="border: 1px solid #aaa;" | 0.0
| style="border: 1px solid #aaa;" | 503
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|-
|- class="unsortable"
! scope="row" |
! colspan=2 scope="row" style="border: 1px solid #aaa; text-align: left;" | {{nobold|Parties with fewer than 500 votes each}}
| style="border: 1px solid #aaa;" | TBD
|{{N/A|}}
|{{N/A|}}
|{{N/A|}}
|{{N/A|}}
|{{N/A|}}
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
| style="border: 1px solid #aaa;" |
|- class="unsortable"
!scope="row" colspan=3 style="border: 1px solid #aaa; text-align: left;" | {{nobold|Blank and invalid votes}}
!colspan=6 |
! style="border: 1px solid #aaa;" | TBD
! style="border: 1px solid #aaa;" | —
! style="border: 1px solid #aaa;" | —
|- class="unsortable" style="background-color:#F2F2F2
! colspan=3 style="border: 1px solid #aaa; text-align:left;" | Total
! style="border: 1px solid #aaa;" | 4515
! style="border: 1px solid #aaa;" | 650
! style="border: 1px solid #aaa;" |
! style="border: 1px solid #aaa;" |
! style="border: 1px solid #aaa;" | 0
! style="border: 1px solid #aaa;" | 100
! style="border: 1px solid #aaa;" | TBD
! style="border: 1px solid #aaa;" | 100
! style="border: 1px solid #aaa;" | 0.0
|- class="unsortable"
! colspan=3 scope="row" style="border: 1px solid #aaa; text-align:left " | Registered voters, and turnout
!colspan=6 |
! style="border: 1px solid #aaa;" | TBD
! style="border: 1px solid #aaa;" | TBD
! style="border: 1px solid #aaa;" | TBD
|}<noinclude>

Revision as of 17:47, 5 July 2024

Discussion

The edit and discuss links make it easier to edit the table and easier to discuss the election results in the right place. Electionworld = Wilfried (talk 22:02, 2 July 2006 (UTC)[reply]

I suppose, but they also have the potential to reduce readability and confuse readers by adding metacontent in unusual places. Then again, given how WP structures its elections articles, the links may be necessary after all...
Or how about leaving only the "Edit" link? Comments/questions are far more likely to be noticed on a relevant article page (Jordan, Elections in Jordan) or a WikiProject page (Wikipedia:WikiProject Elections and Referenda, Wikipedia:WikiProject Elections and Referenda/Overview of results) than the template itself, no? --zenohockey 22:17, 2 July 2006 (UTC)[reply]
What would be the best place to discuss: the Elections in Jordan article, the Politics of Jordan article, the Parliament of Jordan article or the article on this specific election. I would really prefer to have the discuss link in. Electionworld = Wilfried (talk 07:04, 3 July 2006 (UTC)[reply]
  • Can we at least make the edit and discuss links smaller, using <small> or <span style="font-size:80%"> or similar? Or use an existing view/edit template like Tnavbar if appropriate? Wantok (toktok) 01:53, 20 July 2007 (UTC)[reply]

Given it's simplicity, this template should just be subst'd. ed g2stalk 19:23, 22 July 2006 (UTC)[reply]

Sortable

This needs to allow class="wikitable sortable" to be specifiable in the table. With all the numeric data in election results it's an obvious feature to have.

Of course it can't be added willy-nilly. Existing transclusions will need to explicitly switch sortability on and add class="unsortable" to any relevant columns. Possible implementations:

  1. having sortable as a parameter of this template which would be trigger class="wikitable sortable" inside the table
  2. having class as a parameter, passed straight through to the table
  3. having table-params as a parameter, passed straight through to the table
  4. having a separate Template:Electionsorttable based on this Template

The disadvantage of 3 and maybe of 2 is that the existing table style parameters (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%;") could be overridden: does that defeat their standardization purpose? jnestorius(talk) 13:17, 25 September 2007 (UTC)[reply]

The best way is option 4 with a layout as similar as possible to the existing template, I think. Electionworld Talk? 16:00, 29 September 2007 (UTC)[reply]

The advantage is it's easy to code up the template. The disadvantage is having to maintain two otherwise identical templates in parallel. jnestorius(talk) 21:16, 29 September 2007 (UTC)[reply]

I know, but what alternative can be made without having to chnage each entry where the template is used. Electionworld Talk? 08:14, 30 September 2007 (UTC)[reply]

Lots of templates have optional named parameters. (e.g. Template:cite book, title is the only mandatory parameter) Adding an extra optional parameter with default behaviour if it's absent will work in pre-existing transclusions where the parameter will obviously be absent. The wikicode to make this work is a bit complicated; I'm unsure of it, but I'm sure someone else could code it up easily. jnestorius(talk) 14:12, 30 September 2007 (UTC)[reply]
Do you know whom? Electionworld Talk? 17:58, 30 September 2007 (UTC)[reply]
No, but it should be easy to request help once we've agreed on precisely what we're looking for. jnestorius(talk) 21:38, 30 September 2007 (UTC)[reply]

Would it be possible to make these tables sortable (or at least optionally sortable)? --Eleassar my talk 11:57, 22 September 2008 (UTC)[reply]

Second that. Would be useful to be able to sort a long table like MEPs for the Netherlands 2009-2014 by party, by group, by number of votes, or by date of entry into the parliament - basically by every single column. Would adding class=sortable to this template not do the trick? Classical geographer (talk) 14:25, 3 August 2009 (UTC)[reply]
I now noticed the topic has been dicussed before, and have moved these last two remarks below the existing discussion. It seems the technology is not as straightforward as I hoped, but adding an optional parameter sounds great - if someone is willing to program it. Classical geographer (talk) 14:28, 3 August 2009 (UTC)[reply]

Please change the discuss and edit links to something like "v • d • e" used everywhere. Thanks. This shouldn't be protected. ☆ CieloEstrellado 15:33, 29 October 2007 (UTC)[reply]

Query

I dont understand the purpose of this template. Why dont we just build the table in the article space, instead of a template-space? kawaputratorque 12:01, 16 February 2008 (UTC)[reply]

Title

In Mozilla Firefox the title bunches around the edges of links. Could someone please fix this. ChrisDHDR 07:41, 9 May 2008 (UTC)[reply]

Merge

If this is the preferred template, and Template:Election table is not but continues to be used/abused, then merging the two and redirecting the other here should fix any conficts. - Trevor MacInnis (Contribs) 15:11, 3 October 2008 (UTC)[reply]

I propose changing the [edit] [discuss] links to use

{{navbar|{{subst:PAGENAME}}|mini=1}}

which would produce

Any objections? Thanks! Plastikspork (talk) 23:44, 22 July 2009 (UTC)[reply]

Proposed solution: sortable, v/e/d

{{editprotected}} I've made Template:Electiontable/proposed which adds 3 features. The first 2 are suggested above.

  • Changes [edit] [discuss] links to use {{navbar}}.
  • Has a {{Electiontable|...|sortable=yes}} parameter if you want to make your table sortable. This is off by default as you need to tweak each template to make this work.
  • Allows title to be in the format {{Electiontable|Template name|Title}} in addition to the current {{Electiontable|Template name}} '''Title'''. I'm adding this to make this template use navbar in the same way most of the other templates do.

The changes are backwards compatible: I've tested it on Template:United Kingdom parliamentary election, 2005 and the example code on the page. --h2g2bob (talk) 22:11, 16 August 2009 (UTC)[reply]

 DoneTheDJ (talkcontribs) 22:43, 16 August 2009 (UTC)[reply]

Is there a reason the reader should be prevented from viewing a redirected talk page, when pressing the 'd' link? 117Avenue (talk) 00:02, 30 July 2011 (UTC)[reply]

Problem with absent metadata

If you look at Colombian presidential election, 2006 you can see that in the absence of a template giving metadata for the party's "shortname" it inserts the text "Alternative Democratic Pole|Template:Alternative Democratic Pole/meta/shortname". Obviously that can be fixed in this one instance by creating the relevant metadata, but is there a way the table can be changed so that in the absence of a "shortname" template, it just inserts the name?--82.35.251.109 (talk) 02:45, 30 June 2012 (UTC)[reply]

You want Template:Infobox election, there you'll see that the party_name parameter does what you want. 117Avenue (talk) 05:44, 30 June 2012 (UTC)[reply]

The View/edit links look a bit odd. Can we do away with them. They are no used very often anyway (IMO). -- Alan Liefting (talk - contribs) 22:26, 17 August 2012 (UTC)[reply]

When this template, is used in a template, that can't be edited from an article, it is appropriate to have a link that can get you there. 117Avenue (talk) 05:22, 18 August 2012 (UTC)[reply]
If, for arguments sake, the links were not there editors can still get to the template by other means. It is less convenient but given that the templates only get a flurry of editing when first set up they is no need to have the two links there until the death of the WP servers. How about making it optional? -- Alan Liefting (talk - contribs) 06:01, 18 August 2012 (UTC)[reply]
They are already optional, since this doesn't have to be used in a template. But I would suggest against removing them, when it is used on a different page. Sure, we know how to get there, but novice users don't, and on election day that is where the flurry of edits come from. If this becomes a problem, protect the page, but hiding links is sneaky, and not the spirit of Wikipedia. 117Avenue (talk) 02:00, 19 August 2012 (UTC)[reply]

Undo

I believe it was the edit at 11:16, 9 January 2015‎ by User:Gadget850 that has messed up the spacing of all the templates on wikipedia. Please do something to revert it. Thank you. Lmmnhn (talk) 19:19, 14 January 2015 (UTC)[reply]

Template-protected edit request on 19 May 2015

Please either make electiontable a wikitable as per <https://en.wikipedia.org/w/index.php?title=Template:Election_table/sandbox&diff=663104224&oldid=642588896>. Note that some styles have been retained. I have tested the changes on the template testcases, however, they are rather uncomprehensive. 87.254.70.96 (talk) 17:08, 19 May 2015 (UTC)[reply]

Done - for future reference, please note that you can't have multiple class attributes. Alakzi (talk) 19:46, 19 May 2015 (UTC)[reply]

Template-protected edit request on 23 November 2020

Please fix the code editing as to prevent excess spacing from being rendered above table in transclusions, as can be seen from here, for instance. Hildeoc (talk) 05:13, 23 November 2020 (UTC)[reply]

 Not done: I removed a line break in the article, which fixed it for me. Please confirm that looks okay for you too? — Martin (MSGJ · talk) 11:52, 23 November 2020 (UTC)[reply]
@MSGJ: Thanks for fixing that! It's fine in the article now. However, I don't get why that single blank line caused the rendering of excess line spacing there. Normally, a single blank line in the source code does not evoke this issue, right?--Hildeoc (talk) 09:24, 24 November 2020 (UTC)[reply]
You're right. There is something not quite right about this template. When I substitute Template:2016DCDem a blank line appears even though there is no blank line showing in the wikicode of Template:Election table. I think a visit to WP:VPT may be needed because I can't see what's wrong. — Martin (MSGJ · talk) 11:28, 24 November 2020 (UTC)[reply]
@MSGJ: information Note: Wikipedia:Village_pump_(technical)#Template:Election_table.--Hildeoc (talk) 22:23, 25 November 2020 (UTC)[reply]
This extraneous linespace may be related to Wikimedia parser bug T18700 where nested templates can lose track of whether output is currently at the start of a line or not. I've seen this with {{taxobox}} and {{clade}}. If it is the issue, then a workaround is placing a <nowiki/> tag before the table in the template, which for some obscure reason prevents the extra line. —  Jts1882 | talk  15:30, 26 November 2020 (UTC)[reply]

Add sticky-header option

So that readers can see the headers of a long table without repeatedly scrolling to the top, can an admin please add the option of adding sticky-header as a parameter similar to sortable?

In the wikitext, one must first add {{sticky-header}} before the table and add sticky-header to the table's class.

Thanks, cmɢʟeeτaʟκ 14:38, 5 July 2024 (UTC)[reply]

Test version in sandbox:
{{Election table|title=Summary of [[Mars|Martian]] election results, 2020 |sticky-header=yes}}
|-
! colspan="2" style="text-align:left;" | Parties
! Votes
! %
! ±
! Seats
! ±
|-
| style="background-color:#ff0000;" |
| style="text-align:left;" | The red party
| 6042
| 45.40
| −4.41
| 23
| −2
|-
| style="background-color:#00ff00;" |
| style="text-align:left;" | The green party
| 5678
| 42.67
| +1.23
| 21
| 0
|-
| style="background-color:#0000ff;" |
| style="text-align:left;" | Free Mars
| 345
| 2.59
| +2.59
| 1
| +1
|-
| style="background-color:#eeeeee;" |
| style="text-align:left;" | None of the above (unfilled seats)
| 1242
| 9.33
| +0.59
| 5
| +1
|-
! colspan="2" style="text-align:left;" | Total
! 13307
! style="text-align:center;" colspan="2"| 100%
! style="text-align:center;" colspan="2"| 50
|}
This places the template {{sticky-header}} before the table, but I think this can introduce a spurious blank line when the sticky parameter isn't used. I'll use this example on this page to test a way around this.  —  Jts1882 | talk  16:18, 5 July 2024 (UTC)[reply]
@Cmglee: The sandbox version seems to work. Can you test it on the example table you want to use it on or give me the page here?  —  Jts1882 | talk  16:44, 5 July 2024 (UTC)[reply]
@Jts1882: Thank you so much for the quick response. I wish to use it on Template:2024_United_Kingdom_parliamentary_election and reproducing it below, it's perfect except that the sticky header did not include the second row of the header. I'm unsure what the best solution is. Cheers, cmɢʟeeτaʟκ 17:47, 5 July 2024 (UTC)[reply]


Cite error: There are <ref group=lower-alpha> tags or {{efn}} templates on this page, but the references will not show without a {{reflist|group=lower-alpha}} template or {{notelist}} template (see the help page).