|This is a documentation subpage for Template:Canadian election result/top.|
It contains usage information, categories and other content that is not part of the original template page.
TemplateData for Canadian election result/top
The header for a table of the Canadian election results
The two-letter code for a province/territory, the three-letter code for a city, or CA for federal.
The four-digit year for a general election, or some other text (for example a full date) for a by-election.
The full title of a Wikipedia article about a riding. For example: 'Barrie (electoral district)'
The displayed text for the riding name, if different from the above. For example: 'Barrie'.
Set to 'yes' for by-elections. When using this, give the full date of the by-election rather than just the year.
Pagename for by-election.
Text describing reason for by-election, added on line below main title. For example: 'Resignation of [[Bugs Bunny]]'
|Add percent column|
Set to 'yes' to add a column with the heading '%'.
|Add change column|
Set to 'yes' to add a column with the heading '∆%'.
|Add expenditures column|
Set to 'yes' to add a column with the heading 'Expenditures'.
|Add elected column|
Set to 'yes' for ridings that elect multiple members off of one ballot to add a column for with the heading 'Elected'.
|Add 1st ballot column|
Set to 'yes' for ridings with multiple-rounds of voting to create a column for the first round of voting.
|Add final ballot column|
Set to 'yes' for ridings with multiple-rounds of voting to create a column for the final round of voting.
|Add second percent column|
Set to 'yes' for ridings with multiple-rounds of voting to add a column for percents for the final round.
|Mark as multi-ballot riding|
Set to A, B, or C for ridings that run multiple ballots each with a different slate of candidates during each election. It will only change the links in the heading.
|''Future'' election date|
The date of an upcoming election “YYYY-MM-DD” (or other machine interpretable date) to add a coloured title line “The YYYY general/municipal election will be held on Month day.” or (if parameter by=yes) “The by-election will be held on Month day, year.”
|Note results ''Preliminary''|
Setting any value other than “no” adds the large title line “ ** Preliminary results — Not yet official ** ”
The table is by default collapsible. You can set the initial collapsedness to 'yes', 'auto', or 'no'. These correspond to initial states of 'collapsed', 'autocollapse', or 'none', respectively. For instance, if an article about a riding has a long list of election results from years past, you may want to have the first one display (for the most recent election) but keep the previous election years collapsed.