⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 stat_main.php

📁 学校网站源码http://您的网址/admin/admin_login.asp 默认登录用户:admin 默认登录密码:admin
💻 PHP
字号:
<?php
/*********************/
/*                   */
/*  DeZend For PHP5  */
/*  BY WwW.DeZend.CC */
/*   With Bendy [1]  */
/*                   */
/*********************/

include( "../config.inc.php" );
include( "../includes/SysGlobal.php" );
include( "language/".$aLan."_".$charset.".php" );
include( "../includes/version.php" );
include( "../includes/pro.php" );
include( "func/adm.inc.php" );
include( "func/common.inc.php" );
include( "func/stat.inc.php" );
include( "func/db.inc.php" );
include( "func/nocatch.php" );
needauth( 71 );
echo "<html>\r\n<head >\r\n<meta http-equiv=\"Content-Type\" content=\"text/html; charset=";
echo $charset;
echo "\">\r\n<link id=\"style_sheet\" href=\"css/commonstyle.css\" type=\"text/css\" rel=\"stylesheet\">\r\n<title>";
echo $strAdminTitle;
echo "</title>\r\n</head>\r\n\r\n<body  class=\"NormalPage\">\r\n<div align=\"center\">\r\n  <table width=\"100%\" border=\"0\" cellspacing=\"1\" cellpadding=\"0\" align=\"center\" background=\"images/mu8.gif\" height=\"30\" >\r\n    <tr> \r\n      <td width=\"250\" >&nbsp;&nbsp;<img src=\"images/bar.gif\" width=\"13\" height=\"12\">&nbsp;&nbsp;";
echo $strStatCommon;
echo "</td>\r\n      <td >&nbsp;</td>\r\n      <td width=\"100\" >&nbsp;</td>\r\n    </tr>\r\n    \r\n  </table>\r\n\r\n\r\n\r\n  \r\n  ";
statbase( );
$nowtime = time( );
$year = date( "Y", $nowtime );
$month = date( "n", $nowtime );
$day = date( "j", $nowtime );
$date = $day."th_day";
$datas = getyear( $year, $month );
$now = date( "Y-n-j H:i:s", $nowtime );
$agv_day = ( $nowtime - $StartTime ) / ( 3600 * 24 );
$agv_day < 1 ? ( $agv_day = 1 ) : ( $agv_day = round( $agv_day ) );
$agv_month = ( $nowtime - $StartTime ) / ( 3600 * 24 * $datas );
$agv_month < 1 ? ( $agv_m = 1 ) : ( $agv_m = round( $agv_month ) );
$sum_year = "1th_day + 2th_day + 3th_day + 4th_day + 5th_day + 6th_day + 7th_day + 8th_day + 9th_day + 10th_day + 11th_day + 12th_day + 13th_day + 14th_day + 15th_day + 16th_day + 17th_day + 18th_day + 19th_day + 20th_day + 21th_day + 22th_day + 23th_day + 24th_day + 25th_day + 26th_day + 27th_day + 28th_day + 29th_day + 30th_day + 31th_day";
$m = 1;
for ( ;	$m <= 12;	$m++	)
{
	$msql->query( "select {$sum_year} as sum from {$tbl_stat_date} where id = '{$m}'" );
	if ( $msql->next_record( ) )
	{
		$countid_month = $msql->f( "sum" );
	}
	$countid_year += $countid_month;
}
$sum = "1th_day + 2th_day + 3th_day + 4th_day + 5th_day + 6th_day + 7th_day + 8th_day + 9th_day + 10th_day + 11th_day + 12th_day + 13th_day + 14th_day + 15th_day + 16th_day + 17th_day + 18th_day + 19th_day + 20th_day + 21th_day + 22th_day + 23th_day + 24th_day + 25th_day + 26th_day + 27th_day + 28th_day + 29th_day + 30th_day + 31th_day";
$msql->query( "select {$sum} as sum from {$tbl_stat_date} where id = '{$month}'" );
if ( $msql->next_record( ) )
{
	$countid_month = $msql->f( "sum" );
}
$msql->query( "SELECT {$date} FROM {$tbl_stat_date} WHERE id = '{$month}'" );
if ( $msql->next_record( ) )
{
	$countid_day = $msql->f( $date );
}
echo " <br>\r\n  <table width=\"625\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" align=\"center\" height=\"22\">\r\n    <tr> \r\n      <td class=title align=\"left\" height=\"22\" valign=\"top\" width=\"3\"><img src=\"images/menubg16.gif\" width=\"3\" height=\"30\"></td>\r\n      <td class=title align=\"center\" height=\"22\" colspan=\"2\">";
echo $strStatCommon;
echo "</td>\r\n      <td class=title align=\"right\" height=\"22\" width=\"3\" valign=\"top\"><img src=\"images/menubg17.gif\" width=\"3\" height=\"30\"></td>\r\n    </tr>\r\n  </table>\r\n  <table width=\"625\" border=\"0\" cellpadding=\"4\" cellspacing=\"1\">\r\n    <tr> \r\n      <td align=\"right\" class=title width=\"120\">";
echo $strStatStart;
echo "</td>\r\n      <td width=\"200\"  class=con >";
echo date( "Y-n-j H:i:s", $StartTime );
echo "</td>\r\n      <td width=\"120\"  class=title >";
echo $strStatTotal;
echo "</td>\r\n      <td  class=con >";
echo $count_base + $countid_year;
echo "</td>\r\n    </tr>\r\n    <tr> \r\n      <td align=\"right\" class=title width=\"120\">";
echo $strStatTotalYear;
echo "</td>\r\n      <td width=\"200\"  class=con >";
echo $count_base + $countid_year;
echo "</td>\r\n      <td width=\"120\"  class=title >";
echo $strStatTotalMon;
echo "</td>\r\n      <td  class=con >";
echo $count_base + $countid_month;
echo "</td>\r\n    </tr>\r\n    <tr> \r\n      <td align=\"right\" class=title width=\"120\">";
echo $strStatTotalMonP;
echo "</td>\r\n      <td width=\"200\"  class=con >";
echo number_format( ( $count_base + $countid_year ) / $agv_m, 2 );
echo "</td>\r\n      <td width=\"120\"  class=title >";
echo $strStatTotalDayP;
echo "</td>\r\n      <td  class=con >";
echo number_format( ( $count_base + $countid_year ) / $agv_day, 2 );
echo "</td>\r\n    </tr>\r\n    <tr> \r\n      <td align=\"right\" class=title width=\"120\">";
echo $strStatTotalDay;
echo "</td>\r\n      <td colspan=\"3\"  class=con >";
echo $count_base + $countid_day;
echo "</td>\r\n    </tr>\r\n  </table>\r\n    \r\n  <table width=\"625\" border=\"0\" cellpadding=\"4\" cellspacing=\"1\">\r\n    <tr> \r\n      <td align=\"center\"  class=title colspan=\"5\" height=\"25\">";
echo $strStatFrom10;
echo "</td>\r\n    </tr>\r\n    <tr> \r\n    \r\n  <td align=\"center\"  class=title width=\"120\" height=\"25\">";
echo $strStatFtime;
echo "</td>\r\n      <td align=\"center\"  class=title width=\"100\" height=\"25\">";
echo $strStatFIP;
echo "</td>\r\n      <td align=\"center\"  class=title height=\"25\">";
echo $strStatFUrl;
echo "</td>\r\n      <td align=\"center\"  class=title height=\"25\">";
echo $strStatFPage;
echo "</td>\r\n      <td align=\"center\"  class=title height=\"25\" width=\"60\">";
echo $strStatFPerson;
echo "</td>\r\n    </tr>\r\n    ";
$msql->query( "select * from {$tbl_stat_count} {$sql} order by id desc limit 0,10" );
while ( $msql->next_record( ) )
{
	$time = $msql->f( "time" );
	$ip = $msql->f( "ip" );
	$os = $msql->f( "os" );
	$ie = $msql->f( "browse" );
	$from = $msql->f( "urlform" );
	$nowpage = $msql->f( "nowpage" );
	$member = $msql->f( "member" );
	$time = date( "Y-n-j H:i:s", $time );
	$from1 = csubstr( $from, 0, 18, 1 );
	$nowpage1 = str_replace( $SiteUrl, "", $nowpage );
	$nowpage1 = csubstr( $nowpage1, 0, 18, 1 );
	if ( substr( $member, 0, 2 ) == "10" || substr( $member, 0, 2 ) == "11" )
	{
		$member1 = $strGuest;
	}
	else
	{
		$member1 = $member;
	}
	if ( $from1 == "" )
	{
		$from1 = $strStatInput;
	}
	echo " \r\n    <tr> \r\n      <td  class=con align=\"center\" width=\"120\">&nbsp;";
	echo $time;
	echo "</td>\r\n      <td  class=con align=\"center\" width=\"100\" >&nbsp;";
	echo $ip;
	echo "</td>\r\n      <td  class=con >&nbsp;";
	echo "<a href={$from} target=_blank title='{$from}'><font color=#000000>{$from1}</font></a>";
	echo "</td>\r\n      <td  class=con >&nbsp;";
	echo "<a href={$nowpage} target=_blank title='{$nowpage}'><font color=#000000>{$nowpage1}</font></a>";
	echo "</td>\r\n      <td  class=con width=\"60\" align=\"center\" style=\"cursor:hand\" onClick=\"window.location='stat_member.php?member=";
	echo $member;
	echo "'\" >";
	echo $member1;
	echo "</td>\r\n    </tr>\r\n    ";
}
echo " \r\n  </table>\r\n    \r\n  <table width=\"623\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" align=\"center\" height=\"10\" background=\"images/mu1.jpg\">\r\n    <tr> \r\n        <td  align=\"center\" height=\"2\" colspan=\"2\"></td>\r\n      </tr>\r\n    </table>\r\n  \r\n</div>\r\n</body>\r\n</html>\r\n";
?>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -