$totvotes = $yescount + $nocount + $undcount + $uncast; $yesper = $yescount / $totvotes * 100; $noper = $nocount / $totvotes * 100; $undper = $undcount / $totvotes * 100; $uncper = $uncast / $totvotes * 100; $totvotes = $preyescount + $prenocount + $preundcount; $preyesper = $preyescount / $totvotes * 100; $prenoper = $prenocount / $totvotes * 100; $preundper = $preundcount / $totvotes * 100; //before we write to the DB lets figure out the stats? $txt = $date.": " . $logstr; $myfile = file_put_contents($logfile, $txt.PHP_EOL , FILE_APPEND | LOCK_EX); ?>
Polling:
Where users of this calculator stand
if (isMobile()) { print '
'; } else { print '
'; } print "\n"; ?>