php调查系统2

//名称:showresult.php3 //本程序用于查看投票结果 //作者:phpstudent //$vpollselect polltitle from poll where pollselect chioceid,chiocename,chiocenum,chiocecolor from pollchioce where poll “; $vpollcolor=””; $votetotal=0; $vchiocename=split(“,”,”1,2,3,4,5,6,7,8″); while($db->rstnext()) //取出选项的文字,计数及颜色 { $vchiocename[$i]=$db->getitem(2); if($i==0) { $vpolldata=$db->getitem(3); $vpollcolor=$db->getitem(4); } else {$vpolldata.=”,”; $vpolldata.=$db->getitem(3); $vpollcolor.=”,”; $vpollcolor.=$db->getitem(4); } $votetotal+=$db->getitem(3); $i++; }; $vchiocenum=split(“,”,$vpolldata); $vchiocecolor=split(“,”,$vpollcolor); $db->closeresultset(); $db->closeconnection(); if($votetotal==0) echo(“尚未投票”); else {echo(“调查标题:”.$vpolltitle.””); echo(“ =================================================

http://www.bkjia.com/phpjc/532222.htmlwww.bkjia.comtruehttp://www.bkjia.com/phpjc/532222.htmltecharticle//名称:showresult.php3 //本程序用于查看投票结果 //作者:phpstudent //$vpollid=1; 传递参数 调查id require(database.php3); $db = new database(); $db->opendefa…

Posted in 未分类