alietr wrote:I believe this is the code that calculates the percentages. If someone who knows code better than me is able to figure out how to get the percentages to calculate like they used to, I will implement the change. Thanks for any help!
- Code: Select all
foreach ($poll_info as $poll_option)
$option_pct = ($poll_total > 0) ? $poll_option['poll_option_total'] / $poll_total : 0;
$option_pct_txt = sprintf("%.1d%%", round($option_pct * 100));
The fix requires more data. Where is poll_total counted? Maybe it needs to count one per voter instead of one per option. Either that, or there might be another variable called something like voter_total. I'd need to hunt around in various parts of the polling code to suggest the best way to fix it.