<?php include("sql/conn.php"); 
session_start(); 
?>


<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>用户喜欢的网页游戏和页游平台排行榜|<?php include("adm/all/gjz.txt"); ?></title>
<meta name="description" content="用户喜欢的网页游戏和页游平台排行榜|<?php include("adm/all/description.txt"); ?>" />
<meta name="keywords" content="用户喜欢的网页游戏和页游平台排行榜|<?php include("adm/all/gjz.txt"); ?>" />
<link  href="css/css<?php include("adm/all/css.txt"); ?>.css" rel="stylesheet" type="text/css">
</head>

<?Php
$noww = time();
$y = date("Y",$noww);
$m = date("m",$noww);
$d = date("d",$noww);
$yy = date("Y",$noww - 86400);
$ym = date("m",$noww - 86400);
$yd = date("d",$noww - 86400);
$se = array('FF0000','00FFFF','0000FF','0000A0','FF0080','800080','FFFF00','00FF00','FF00FF');
?>


<body >


<div id="top">
<?php include("user.php");  ?>
</div>
<?php include("gh.php");  ?>
<div align="center">

<?php include("logo.php");  ?>


<div id="dh" ><?php 
 if(file_exists("dh1.php"))
 {
include("dh1.php"); 
 }
 else
 {
include("action/dh1.php"); 
 }
?></div>



</div>



<div class="clear"></div>


<?php 
 if(file_exists("top.php"))
 {
include("top.php"); 
 }
 else
 {
include("action/top.php"); 
 }
?>


<div class="clear"></div>


<div align="center">
<div id="nr">



<div class="RoundedCorner">
<b class="rtop"><b class="r1"></b><b class="r2"></b><b class="r3"></b><b class="r4"></b></b>


<table>
  <tr>
    <td colspan="4" align="center"><h3>天天PK网页游戏开服表 用户使用情况统计</h3>  <hr></td>
    </tr>
  <tr>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td><strong><?php echo $y."年".$m."月".$d."日" ;?></strong></td>
    <td><strong><?php echo $yy."年".$ym."月".$yd."日" ;?></strong></td>
  </tr>
  <tr>
    <td><p><strong>服务</strong></p>
      <p><strong>平台</strong></p></td>
    <td><p>&nbsp;</p>      </td>
    <td><object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" 
codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0"
width="368" height="228" align="" viewastext>
      <param name="movie" value="img/round.swf?chartWidth=368&ChartHeight=228" />
      <param name="allowScriptAccess" value="sameDomain" />
      <param name="quality" value="high" />
      <param name="wmode" value="transparent" />
      <param name="FlashVars" value="&dataXML=<graph shownames='1' showvalues='0' decimalPrecision='0' pieRadius='138' numberPrefix='' formatNumber='1' formatNumberScale='0'  baseFont='Verdana' baseFontSize='12' outCnvBaseFontSze='Verdana' outCnvBaseFontSize='10'>
<?php
$i = 0;
$result = mysql_query("SELECT * FROM tongji WHERE today='y' and kf <> '' ORDER BY text ");
while($row = mysql_fetch_array($result))
  {
echo "<set name='".$row['kf']."' value='".$row['text']."' color='".$se[$i]."'/>";
$i++;
if($i==9)
$i=0;
  }
?>
</graph>" />
    </object></td>
    <td>
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" 
codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0"
width="368" height="228" align="" viewastext>
      <param name="movie" value="img/round.swf?chartWidth=368&ChartHeight=228" />
      <param name="allowScriptAccess" value="sameDomain" />
      <param name="quality" value="high" />
      <param name="wmode" value="transparent" />
      <param name="FlashVars" value="&dataXML=<graph shownames='1' showvalues='0' decimalPrecision='0' pieRadius='138' numberPrefix='' formatNumber='1' formatNumberScale='0'  baseFont='Verdana' baseFontSize='12' outCnvBaseFontSze='Verdana' outCnvBaseFontSize='10'>
<?php
$i = 0;
$result = mysql_query("SELECT * FROM tongji WHERE yestoday='y' and kf <> '' ORDER BY text ");
while($row = mysql_fetch_array($result))
  {
echo "<set name='".$row['kf']."' value='".$row['text']."' color='".$se[$i]."'/>";
$i++;
if($i==9)
$i=0;
  }
?>
</graph>" />
    </object>	</td>
  </tr>
  <tr>
    <td><p><strong>游戏</strong></p>
      <p><strong>名称</strong></p></td>
    <td><p>&nbsp;</p>      </td>
    <td>
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" 
codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0"
width="368" height="228" align="" viewastext="viewastext">
      <param name="movie" value="img/round.swf?chartWidth=368&amp;ChartHeight=228" />
      <param name="allowScriptAccess" value="sameDomain" />
      <param name="quality" value="high" />
      <param name="wmode" value="transparent" />
      <param name="FlashVars" value="&dataXML=<graph shownames='1' showvalues='0' decimalPrecision='0' pieRadius='138' numberPrefix='' formatNumber='1' formatNumberScale='0'  baseFont='Verdana' baseFontSize='12' outCnvBaseFontSze='Verdana' outCnvBaseFontSize='10'>
<?php
$i = 0;
$result = mysql_query("SELECT * FROM tongji WHERE today='y' and name <> '' ORDER BY text ");
while($row = mysql_fetch_array($result))
  {
echo "<set name='".$row['name']."' value='".$row['text']."' color='".$se[$i]."'/>";
$i++;
if($i==9)
$i=0;
  }
?>
</graph>" />
    </object>	</td>
    <td>
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" 
codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0"
width="368" height="228" align="" viewastext="viewastext">
      <param name="movie" value="img/round.swf?chartWidth=368&amp;ChartHeight=228" />
      <param name="allowScriptAccess" value="sameDomain" />
      <param name="quality" value="high" />
      <param name="wmode" value="transparent" />
      <param name="FlashVars" value="&dataXML=<graph shownames='1' showvalues='0' decimalPrecision='0' pieRadius='138' numberPrefix='' formatNumber='1' formatNumberScale='0'  baseFont='Verdana' baseFontSize='12' outCnvBaseFontSze='Verdana' outCnvBaseFontSize='10'>
<?php
$i = 0;
$result = mysql_query("SELECT * FROM tongji WHERE yestoday='y' and name <> '' ORDER BY text ");
while($row = mysql_fetch_array($result))
  {
echo "<set name='".$row['name']."' value='".$row['text']."' color='".$se[$i]."'/>";
$i++;
if($i==9)
$i=0;
  }
?>
</graph>" />
    </object>	</td>
  </tr>
  <tr>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
    <td>&nbsp;</td>
  </tr>
</table>








<b class="rbottom"><b class="r4"></b><b class="r3"></b><b class="r2"></b><b class="r1"></b></b>
</div>

</div></div>

<div class="clear"></div>

<div align="center"><div id="nr">


<div class="RoundedCorner">
<b class="rtop"><b class="r1"></b><b class="r2"></b><b class="r3"></b><b class="r4"></b></b>
<div id="nr2">


<?php 
 if(file_exists("12.php"))
 {
include("12.php"); 
 }
 else
 {
include("action/12.php"); 
 }
?>




</div>
<b class="rbottom"><b class="r4"></b><b class="r3"></b><b class="r2"></b><b class="r1"></b></b>
</div>


</div></div>


<div class="clear"></div>



<?php 
 if(file_exists("foot.php"))
 {
include("foot.php"); 
 }
 else
 {
include("action/foot.php"); 
 }
?>

</body>



<?php
$result = mysql_query("SELECT * FROM tongji  LIMIT 0,1");
while($row = mysql_fetch_array($result))
  {
  $bzbz = $row['bz'];
  }
if($noww>$bzbz + 1800 )
{
////////////////////////////////////////////////////
mysql_query("TRUNCATE TABLE tongji"); 
////////////////////////////////////////////////////
$result1 = mysql_query("select distinct kf from outsite where y='".$yy."' and m='".$ym."' and d= '".$yd."' ");
while($row1 = mysql_fetch_array($result1))
  {
$result = mysql_query("SELECT * FROM outsite where y='".$yy."' and m='".$ym."' and d= '".$yd."' and kf = '".$row1['kf']."'");
$num = mysql_num_rows($result);
mysql_query("INSERT INTO tongji (yestoday, kf, text,bz) 
VALUES ('y', '".$row1['kf']."', '".$num."', '".$noww."')");
  }
////////////////////////////////////////////////////
$result1 = mysql_query("select distinct kf from outsite where y='".$y."' and m='".$m."' and d= '".$d."' ");
while($row1 = mysql_fetch_array($result1))
  {
$result = mysql_query("SELECT * FROM outsite where y='".$y."' and m='".$m."' and d= '".$d."' and kf = '".$row1['kf']."'");
$num = mysql_num_rows($result);
mysql_query("INSERT INTO tongji (today, kf, text,bz) 
VALUES ('y', '".$row1['kf']."', '".$num."', '".$noww."')");
  }
//////////////////////////////////////////////////////
//////////////////////////////////////////////////////
$result1 = mysql_query("select distinct name from outsite where y='".$yy."' and m='".$ym."' and d= '".$yd."' ");
while($row1 = mysql_fetch_array($result1))
  {
$result = mysql_query("SELECT * FROM outsite where y='".$yy."' and m='".$ym."' and d= '".$yd."' and name = '".$row1['name']."'");
$num = mysql_num_rows($result);
mysql_query("INSERT INTO tongji (yestoday, name, text,bz) 
VALUES ('y', '".$row1['name']."', '".$num."', '".$noww."')");
  }
////////////////////////////////////////////////////
$result1 = mysql_query("select distinct name from outsite where y='".$y."' and m='".$m."' and d= '".$d."' ");
while($row1 = mysql_fetch_array($result1))
  {
$result = mysql_query("SELECT * FROM outsite where y='".$y."' and m='".$m."' and d= '".$d."' and name = '".$row1['name']."'");
$num = mysql_num_rows($result);
mysql_query("INSERT INTO tongji (today, name, text,bz) 
VALUES ('y', '".$row1['name']."', '".$num."', '".$noww."')");
  }
//////////////////////////////////////////////////////
}

?>



<?php include("sql/close.php"); ?>

