加入
閱讀權限、評分同減、複數購買價格及通知、清空購買名單
/require/readvote.php 增加投票帖統計功能、平均功能、自動選項分數辨識功能(分數:選項提幹)
18行
$votesum = 0;
$votetotal = $votetavg = $votehighest = 0;//
$votedb = $vt_name = $vt_num = $voteid = $voter = array();[
36行
$vt_name[$key] = $option[0];
$vt_num[$key] = $option[1];
$votehighest=$votehighest>$vt_num[$key]?$votehighest:$vt_num[$key];//
$votesum += $option[1];
//
$ifnum=explode(':',$vt_name[$key]);
if($ifnum[0]){
$votetotal+=$ifnum[0]*$vt_num[$key];
}
//
52行
//$vote['width'] = floor(500*$vt_num[$key]/($votesum+1));
$vote['width'] = floor(500*$vt_num[$key]/($votehighest+1));//
63行
$votesum=count(array_unique($allvoter));
$voteavg=round($votetotal/$votesum,3);//