5.9. Poll

Top  Previous  Next

asystemresults.tpl

Local variables:

o

$questions - the array of questions

o

$question.title- the title of a question

o

$question.answers - the array of answers for the question

o

$answer.title - the title of an answer

o

$answer.back_color - the background color for an answer, it is defined at \system\lib\poll\poll.php, $GLOBALS['back_color']

o

$answer.text_color - the text color for an answer, it is defined at \system\lib\poll\poll.php, $GLOBALS['text_color']

o

$answer.rate - the percentage of votes for the answer (relative number)

o

$answer.counter - the number of votes for the answer (absolute number)

o

$question.total_votes - total votes of the question

o

$GLOBALS.site_url -  the global variable containing a full URL of the site

o

$question.id - the ID of the question

 

poll_answer.tpl

Local variables:

o

$answer.id - the ID of an answer

o

$answer.title - the text of an answer

 

poll_block.tpl

Local variables:

o

$GLOBALS.site_url -  the global variable containing a full URL of the site

o

$question.id - the ID of the question

o

$question.title- the title of a question

o

$answers - the array with the answers for the question

o

$question.display - displays the question if the "Display Results" parameter is checked in the "Edit Question" block at Admin Panel -> Content Management -> Online Polls -> edit the question