<?php
file_exists("../include/config.php")?require_once "../include/config.php":die("wrong...");
file_exists("../include/config1.php")?require_once "../include/config1.php":die("wrong...");
file_exists("../include/dbConnection.class.php")?require_once "../include/dbConnection.class.php":die("wrong...");
//file_exists("../include/config.fun.php")?require "../include/config.fun.php":die("wrong...");
file_exists("../include/page.class.php")?require_once "../include/page.class.php":die("wrong...");
$db = new dbConnection(DSN);
$db1 = new dbConnection(DSN1);
$SQL = "select Number from babyvote";
$db -> execute($SQL);
$resut = $db -> fetch();
if($resut == NULL || !is_array($resut))
die("wrong...");
   
foreach($resut as $l)
{
$db1 = new dbConnection(DSN1);
$sql4 = "select sum(vcNum) from votecall where vcNumber = '{$l[0]}' and vcType=1";
$aa = $db1 -> execute($sql4);
$resuss = $db1 -> fetch();
$db1 -> execute("select sum(vcNum) from votecall where vcNumber = '{$l[0]}' and vcType=2");
$re = $db1 -> fetch();
$dbs = new dbConnection(DSN);
$sql5 = "update babyvote set shengxun='{$resuss[0][0]}' where Number = '{$l[0]}'";
$ress = $dbs -> execute("update babyvote set shengxun='{$resuss[0][0]}' where Number = '{$l[0]}'");
$aa = $dbs -> affectedRows;
$sql7 = "update babyvote set tallpiao='{$re[0][0]}' where Number = '{$l[0]}'";
$dbs -> execute($sql7,2);
//echo mysql_error();
//echo $dbs -> affectedRows;
if($dbs -> affectedRows>=0&&$aa>=0)
$aaa[] = $l[0];
}
$fp=fopen(CSURL."dao.php","w");
fwrite($fp,"<?php  define('hutime',time()); ?>");
fclose($fp);
if(count($aaa)<0)
die("系统有误!");

   
?>我想写一段代码来得出:得票之星。。