Details
-
Bug
-
Resolution: Obsolete
-
Medium
-
extension/ezwebin 1.2-1, extension/ezwebin 1.3
-
None
Description
design/ezwebin/templates/content/collectedinfo/poll.tpl:57
{set $percentage = cond( $total_count|gt( 0 ), round( div( mul( $item_count, 100 ),$total_count ) ), 0 )}
With this
{set $percentage = cond( $total_count|gt( 0 ), div( mul( $item_count, 100 ), $total_count ), 0 )}
Steps to reproduce
Create a Poll with a yes/no question
1) Select that object
2) Answer 5 times "yes" to the binary question
3) Anwser 3 times "no" to the binary question
4) View the stats, and check the percentage of "yes" and "no"
Expected results:
62,5% of "yes" and 37,5% "no" => 100%.
Actual results
63% of "yes" and 38% "no" => 101%.