Andreas
08-01-2004, 10:00 PM
If you have a poll where users can vote for multiple options, the total amount of votes is being used to calculate the percent for each option.
Example
3 Options, 10 Voters
Option 1 = 3 votes
Option 2 = 10 votes
Option 3 = 6 votes
Now, it would display 52.6 % for Option 2 (total amount of votes = 19, 10/19 = 52.6%), although all voters clicked Option 2.
This hack changes this behaviour so you would get 30% for Option 1, 100% for Option 2 and 60% for Option 3 in this case.
Attention: This hack is no longer needed for vBulletin > 3.0.6 as it has been fixed in factory code.
Example
3 Options, 10 Voters
Option 1 = 3 votes
Option 2 = 10 votes
Option 3 = 6 votes
Now, it would display 52.6 % for Option 2 (total amount of votes = 19, 10/19 = 52.6%), although all voters clicked Option 2.
This hack changes this behaviour so you would get 30% for Option 1, 100% for Option 2 and 60% for Option 3 in this case.
Attention: This hack is no longer needed for vBulletin > 3.0.6 as it has been fixed in factory code.