Difference between revisions of "Template:Past Poll"

m
Line 1: Line 1:
<noinclude>[[Template:Past Poll]] is designed for use on the [[UOGuide:Polls|Past Polls]] page to display a poll that was once featured on the front page of UOGuide and has since been archived.
+
<noinclude>{{Template Overview
 
+
|usedon=all
==Template==
+
|purpose=display a poll that was once featured on the front page of UOGuide and has since been archived
<pre>
+
|template=<nowiki>{{Past Poll
{{Past Poll
+
 
|question=
 
|question=
 
|option1=
 
|option1=
Line 22: Line 21:
 
|result8=
 
|result8=
 
|totalvotes=
 
|totalvotes=
 +
}}</nowiki>
 +
}}
 +
{{Template Parameter
 +
|name=question
 +
|usage=mandatory
 +
|takes=a string or strings
 +
|denotes=the question that the poll asked voters to choose an answer for
 +
|generates=the question in the header of the template
 +
|validvalues=Any string or strings.
 +
}}
 +
{{Template Parameter
 +
|name=option1
 +
|usage=mandatory
 +
|takes=a string or strings
 +
|denotes=the first option that voters could choose in the poll
 +
|generates=the first option in the poll
 +
|validvalues=Any string or strings.
 +
}}
 +
{{Template Parameter
 +
|name=result1
 +
|usage=mandatory
 +
|takes=a number
 +
|denotes=the percentage of voters that chose the first option in the poll
 +
|generates=the percentage bar that corresponds to the first option in the poll
 +
|validvalues=Any positive number.
 +
}}
 +
{{Template Parameter
 +
|name=option2
 +
|usage=mandatory
 +
|takes=a string or strings
 +
|denotes=the second option that voters could choose in the poll
 +
|generates=the second option in the poll
 +
|validvalues=Any string or strings.
 +
}}
 +
{{Template Parameter
 +
|name=result2
 +
|usage=mandatory
 +
|takes=a number
 +
|denotes=the percentage of voters that chose the first option in the poll
 +
|generates=the percentage bar that corresponds to the first option in the poll
 +
|validvalues=Any positive number.
 +
}}
 +
{{Template Parameter
 +
|name=option3
 +
|takes=a string or strings
 +
|denotes=the third option that voters could choose in the poll
 +
|generates=the third option in the poll
 +
|validvalues=Any string or strings.
 +
}}
 +
{{Template Parameter
 +
|name=result3
 +
|takes=a number
 +
|denotes=the percentage of voters that chose the third option in the poll
 +
|generates=the percentage bar that corresponds to the third option in the poll
 +
|validvalues=Any positive number.
 +
}}
 +
{{Template Parameter
 +
|name=option4
 +
|takes=a string or strings
 +
|denotes=the fourth option that voters could choose in the poll
 +
|generates=the fourth option in the poll
 +
|validvalues=Any string or strings.
 +
}}
 +
{{Template Parameter
 +
|name=result4
 +
|takes=a number
 +
|denotes=the percentage of voters that chose the fourth option in the poll
 +
|generates=the percentage bar that corresponds to the fourth option in the poll
 +
|validvalues=Any positive number.
 +
}}
 +
{{Template Parameter
 +
|name=option5
 +
|takes=a string or strings
 +
|denotes=the fifth option that voters could choose in the poll
 +
|generates=the fifth option in the poll
 +
|validvalues=Any string or strings.
 +
}}
 +
{{Template Parameter
 +
|name=result5
 +
|takes=a number
 +
|denotes=the percentage of voters that chose the fifth option in the poll
 +
|generates=the percentage bar that corresponds to the fifth option in the poll
 +
|validvalues=Any positive number.
 +
}}
 +
{{Template Parameter
 +
|name=option6
 +
|takes=a string or strings
 +
|denotes=the sixth option that voters could choose in the poll
 +
|generates=the sixth option in the poll
 +
|validvalues=Any string or strings.
 +
}}
 +
{{Template Parameter
 +
|name=result6
 +
|takes=a number
 +
|denotes=the percentage of voters that chose the sixth option in the poll
 +
|generates=the percentage bar that corresponds to the sixth option in the poll
 +
|validvalues=Any positive number.
 +
}}
 +
{{Template Parameter
 +
|name=option7
 +
|takes=a string or strings
 +
|denotes=the seventh option that voters could choose in the poll
 +
|generates=the seventh option in the poll
 +
|validvalues=Any string or strings.
 +
}}
 +
{{Template Parameter
 +
|name=result7
 +
|takes=a number
 +
|denotes=the percentage of voters that chose the seventh option in the poll
 +
|generates=the percentage bar that corresponds to the seventh option in the poll
 +
|validvalues=Any positive number.
 +
}}
 +
{{Template Parameter
 +
|name=option8
 +
|takes=a string or strings
 +
|denotes=the eighth option that voters could choose in the poll
 +
|generates=the eighth option in the poll
 +
|validvalues=Any string or strings.
 +
}}
 +
{{Template Parameter
 +
|name=result8
 +
|takes=a number
 +
|denotes=the percentage of voters that chose the eighth option in the poll
 +
|generates=the percentage bar that corresponds to the eighth option in the poll
 +
|validvalues=Any positive number.
 +
}}
 +
{{Template Parameter
 +
|name=totalvotes
 +
|usage=mandatory
 +
|takes=a number
 +
|denotes=the total number of votes that the poll garnered
 +
|generates=the "Total Votes" item in the bottom-right corner of the template
 +
|validvalues=Any positive whole number.
 
}}
 
}}
</pre>
 
 
 
[[Category:Information Templates|{{PAGENAME}}]]</noinclude><includeonly>{| style="border:1px solid #000000; border-collapse:collapse; margin:1px; width:auto;"
 
[[Category:Information Templates|{{PAGENAME}}]]</noinclude><includeonly>{| style="border:1px solid #000000; border-collapse:collapse; margin:1px; width:auto;"
 
|-
 
|-

Revision as of 14:21, 11 December 2009

Template:Past Poll is designed for use on all pages to display a poll that was once featured on the front page of UOGuide and has since been archived.

Template

{{Past Poll
|question=
|option1=
|result1=
|option2=
|result2=
|option3=
|result3=
|option4=
|result4=
|option5=
|result5=
|option6=
|result6=
|option7=
|result7=
|option8=
|result8=
|totalvotes=
}}

Parameters

[[Category:{{{category}}} Templates|Past Poll]]

question

  • Usage: Mandatory
  • Description: The question parameter takes a string or strings denoting the question that the poll asked voters to choose an answer for. This is used to generate the question in the header of the template.
  • Valid Value(s): Any string or strings.

option1

  • Usage: Mandatory
  • Description: The option1 parameter takes a string or strings denoting the first option that voters could choose in the poll. This is used to generate the first option in the poll.
  • Valid Value(s): Any string or strings.

result1

  • Usage: Mandatory
  • Description: The result1 parameter takes a number denoting the percentage of voters that chose the first option in the poll. This is used to generate the percentage bar that corresponds to the first option in the poll.
  • Valid Value(s): Any positive number.

option2

  • Usage: Mandatory
  • Description: The option2 parameter takes a string or strings denoting the second option that voters could choose in the poll. This is used to generate the second option in the poll.
  • Valid Value(s): Any string or strings.

result2

  • Usage: Mandatory
  • Description: The result2 parameter takes a number denoting the percentage of voters that chose the first option in the poll. This is used to generate the percentage bar that corresponds to the first option in the poll.
  • Valid Value(s): Any positive number.

option3

  • Usage: Optional
  • Description: The option3 parameter takes a string or strings denoting the third option that voters could choose in the poll. This is used to generate the third option in the poll.
  • Valid Value(s): Any string or strings.

result3

  • Usage: Optional
  • Description: The result3 parameter takes a number denoting the percentage of voters that chose the third option in the poll. This is used to generate the percentage bar that corresponds to the third option in the poll.
  • Valid Value(s): Any positive number.

option4

  • Usage: Optional
  • Description: The option4 parameter takes a string or strings denoting the fourth option that voters could choose in the poll. This is used to generate the fourth option in the poll.
  • Valid Value(s): Any string or strings.

result4

  • Usage: Optional
  • Description: The result4 parameter takes a number denoting the percentage of voters that chose the fourth option in the poll. This is used to generate the percentage bar that corresponds to the fourth option in the poll.
  • Valid Value(s): Any positive number.

option5

  • Usage: Optional
  • Description: The option5 parameter takes a string or strings denoting the fifth option that voters could choose in the poll. This is used to generate the fifth option in the poll.
  • Valid Value(s): Any string or strings.

result5

  • Usage: Optional
  • Description: The result5 parameter takes a number denoting the percentage of voters that chose the fifth option in the poll. This is used to generate the percentage bar that corresponds to the fifth option in the poll.
  • Valid Value(s): Any positive number.

option6

  • Usage: Optional
  • Description: The option6 parameter takes a string or strings denoting the sixth option that voters could choose in the poll. This is used to generate the sixth option in the poll.
  • Valid Value(s): Any string or strings.

result6

  • Usage: Optional
  • Description: The result6 parameter takes a number denoting the percentage of voters that chose the sixth option in the poll. This is used to generate the percentage bar that corresponds to the sixth option in the poll.
  • Valid Value(s): Any positive number.

option7

  • Usage: Optional
  • Description: The option7 parameter takes a string or strings denoting the seventh option that voters could choose in the poll. This is used to generate the seventh option in the poll.
  • Valid Value(s): Any string or strings.

result7

  • Usage: Optional
  • Description: The result7 parameter takes a number denoting the percentage of voters that chose the seventh option in the poll. This is used to generate the percentage bar that corresponds to the seventh option in the poll.
  • Valid Value(s): Any positive number.

option8

  • Usage: Optional
  • Description: The option8 parameter takes a string or strings denoting the eighth option that voters could choose in the poll. This is used to generate the eighth option in the poll.
  • Valid Value(s): Any string or strings.

result8

  • Usage: Optional
  • Description: The result8 parameter takes a number denoting the percentage of voters that chose the eighth option in the poll. This is used to generate the percentage bar that corresponds to the eighth option in the poll.
  • Valid Value(s): Any positive number.

totalvotes

  • Usage: Mandatory
  • Description: The totalvotes parameter takes a number denoting the total number of votes that the poll garnered. This is used to generate the "Total Votes" item in the bottom-right corner of the template.
  • Valid Value(s): Any positive whole number.