<!DOCTYPE html PUBLIC "-//W3C//Dtd XHTML 1.0 transitional//EN" "http://www.w3.org/tr/xhtml1/Dtd/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title><!--{$cfg.webtitle}--></title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="author" content="">
<meta name="description" content=""/>
<link href="images/index.css" rel="stylesheet" type="text/css">
<script src="js/check.js"></script>
</head>
<body>

<table cellSpacing=0 cellPadding=0 align=center width="960px">
  <tr>
    <td colSpan=3 id="banner"><!--{$cfg.webtitle}--></td>
  </tr>
</table>
<table width="960px" align="center" bgcolor="#FAFAFA">
<form id="form1" name="fm" method="post" action="?action=index&do=vote_add" onsubmit="return checkForm(this)"> 
 <tr>
  <td id="info" colspan="6"></td>
 </tr>
 <tr>
  
 </tr>

 <tr onMouseOver="this.bgColor='#BBFFBB'" onMouseOut="this.bgColor='#BBFFBB'">
  <td colspan="4"><table width="98%" cellpadding="0" cellspacing="5" align="center">
    <tr>
      <td>投票结果</td>
    </tr>

    <tr>
	
      <td align="center">
	<?php
	$sql="select * from votetitle";
	$rs=mysql_query($sql);
	$row=mysql_fetch_assoc($rs);
	echo $row["votetitle"];
     ?>	
</div>
							
<table class='voteItems' cellpadding='0' cellspcaing='0'>
 <?php
	$sql="select sum(count) as 'total' from vote";
	$rs=mysql_query($sql);
	$rows=mysql_fetch_assoc($rs);
	$sum=$rows["total"];	 //
	$sql="select * from vote";
	$rs=mysql_query($sql);
?>


<?php
	while($rows=mysql_fetch_assoc($rs))
	{
?>


	<tr><td class='vi-name'><div class='voteItemName'><?php echo $rows["item"]?></div></td>
	
	<td>
<?php
	$per=$rows["count"]/$sum;
	$per=number_format($per,4);
?>
             <td> 
			 <img src="img/100.jpg" height="13" width="<?php echo $per*100?>" /></td>
			
			<td><?php echo $per*100?>%</td>
		    
			
			<td><?php echo $rows["count"]?>&nbsp;&nbsp;</td>
	<?php
	}
    ?>
 
   </table>
  </td>
 </tr>

  <tr>
    <td colspan="5" align="right">
	<input name="rsCount" type="hidden" id="rsCount" value="" /></td>
  </tr>
  <tr>
    <td colspan="5" align="center"></td>
  </tr>

</form>
</table>

<table cellSpacing=0 cellPadding=0 align=center background="images/qbj.jpg" width="960px">
  <tr>
    <td height=60 align="center"><a href="http://www.dehome.net/" target="_blank">俏迅</a> </td>
  </tr>
</table>

</body>
</html>