<?php require_once("Include/Conn.php")?>
<?php
$AD_ID = isset($_GET["AD_ID"]) ? $_GET["AD_ID"] : "";
if(!is_numeric($AD_ID)) showMsg("参数错误");
$y = isset($_GET["y"]) ? $_GET["y"] : "";
$m = isset($_GET["m"]) ? $_GET["m"] : "";
$d = isset($_GET["d"]) ? $_GET["d"] : "";
if(empty($y)) $y = date("Y");
if(empty($m)) $m = date("m");
if(empty($d)) $d = date("Y-m-d");
$XHType = isset($_GET["XHType"]) ? $_GET["XHType"] : "";
switch($XHType)
{
case "y":
$XHTitle = "年统计";
break;
case "m":
$XHTitle = "月统计(".$y."年)";
break;
case "d":
$XHTitle = "日统计(".$y."年".$m."月)";
break;
case "h":
$XHTitle = "时统计(".$d.")";
break;
default:
$XHTitle = "总体统计";
}
?>
<html>
<head>
<?php showHead()?>
<title>【雪晖广告管理系统】查看广告统计报表</title>
</head>
<body>
<table width="100%" border="0" align="center" cellpadding="1" cellspacing="2" bgcolor="#E1F0FF" id="table1">
<tr>
<td height="35" align="center" bgcolor="#8EC7FF"><strong><a href="Report.php?AD_ID=<?php echo $AD_ID?>">总体统计</a> | <a href="Report.php?AD_ID=<?php echo $AD_ID?>&XHType=y">年统计</a> | <a href="Report.php?AD_ID=<?php echo $AD_ID?>&XHType=m">月统计</a> | <a href="Report.php?AD_ID=<?php echo $AD_ID?>&XHType=d">日统计</a> | <a href="Report.php?AD_ID=<?php echo $AD_ID?>&XHType=h">时统计</a></strong></td>
</tr>
</table>
<table width="100%" border="0" align="center" cellpadding="1" cellspacing="2" bgcolor="#E1F0FF" id="table1">
<form action="" method="get" name="form1">
<input type="hidden" name="AD_ID" value="<?php echo $AD_ID?>">
<tr>
<td width="20%"><strong><?php echo $XHTitle?>>></strong></td>
<td>
<?php
if($XHType=="m")
{
echo "<input type='hidden' name='XHType' value='$XHType'>年份:<input type='text' name='y' value='".date("Y")."' size='5'> <input type='submit' name='submit' value='查看'>";
}
else if($XHType=="d")
{
echo "<input type='hidden' name='XHType' value='$XHType'>年份:<input type='text' name='y' value='".date("Y")."' size='5'> 月份<input type='text' name='m' value='".date("m")."' size='5'> <input type='submit' name='submit' value='查看'>";
}
else if($XHType=="h")
{
echo "<input type='hidden' name='XHType' value='$XHType'>日期:<input type='text' name='d' value='".date("Y-m-d")."' size='10'> <input type='submit' name='submit' value='查看'>";
}
?>
</td>
</tr>
</form>
</table>
<?php if($XHType==""){?>
<?php
$sql = "select * from xhad_ad where AD_ID=".$AD_ID;
$exec = mysql_query($sql,$conn);
if($rs = mysql_fetch_array($exec))
{
$TypeID = $rs["TypeID"];
$BizID = $rs["BizID"];
$Title = $rs["Title"];
$Sort = $rs["Sort"];
$AdUrl = $rs["AdUrl"];
$etime = $rs["EndDateTime"];
$State = $rs["State"];
$Views = $rs["Views"];
$Hits = $rs["Hits"];
}
?>
<!-----总体统计----->
<table width="100%" border="0" align="center" cellpadding="3" cellspacing="5" bgcolor="#E1F0FF" id="table1">
<tr bgcolor="#DDDDFF">
<td width="20%">广告名称:</td>
<td><?php echo $Title?> <?php if((int)$State==0) echo "<font color='red'>(停用)</font>"?></td>
<td width="20%">商户名称:</td>
<td><?php showBiz($BizID)?></td>
</tr>
<tr bgcolor="#F5ECFF">
<td width="20%">广告类别:</td>
<td><?php showType($TypeID)?></td>
<td width="20%">广告类型:</td>
<td><?php showSort($Sort)?></td>
</tr>
<tr bgcolor="#DDDDFF">
<td width="20%">链接地址:</td>
<td><a href="<?php echo $AdUrl?>" target="_blank"><?php echo $AdUrl?></a></td>
<td width="20%">结束时间:</td>
<td><?php echo $etime?></td>
</tr>
<tr bgcolor="#F5ECFF">
<td width="20%">总显示次数:</td>
<td><?php echo $Views?></td>
<td width="20%">总点击次数:</td>
<td><?php echo $Hits?></td>
</tr>
</table>
<!------总体统计结束-------->
<?php }else if($XHType=="y"){?>
<?php
$sql = "select sum(Views) as sv,sum(Hits) as sh from xhad_year where AD_ID=".$AD_ID;
$exec = mysql_query($sql,$conn);
if($rs = mysql_fetch_array($exec))
{
$sv = $rs["sv"];
$sh = $rs["sh"];
}
?>
<!------年统计-------------->
<table width="100%" border="0" align="center" cellpadding="3" cellspacing="5" bgcolor="#E1F0FF" id="table1">
<tr bgcolor="#DDDDFF">
<td width="10%">年份</td>
<td>显示次数</td>
<td width="200">比例</td>
<td>点击次数</td>
<td width="200">比例</td>
</tr>
<?php
$sql = "select * from xhad_year where AD_ID=".$AD_ID." order by ID desc";
$exec = mysql_query($sql,$conn);
while($rs = mysql_fetch_array($exec)){
?>
<tr>
<td><?php echo $rs["CurYear"]?></td>
<td><?php echo $rs["Views"]?></td>
<td><img src="Images/bar1.gif" height="10" width="<?php echo empty($sv) ? 0 : 200*round($rs["Views"]/$sv,3)?>" align="middle"><?php echo empty($sv) ? 0 : (round($rs["Views"]/$sv,3)*100)."%"?></td>
<td><?php echo $rs["Hits"]?></td>
<td><img src="Images/bar1.gif" height="10" width="<?php echo empty($sh)? 0 : 200*round($rs["Hits"]/$sh,3)?>" align="middle"><?php echo empty($sh)? 0 : (round($rs["Hits"]/$sh,3)*100)."%"?></td>
</tr>
<?php }?>
</table>
<!--------年统计结束----------->
<?php }else if($XHType=="m"){?>
<?php
$sql = "select sum(Views) as sv,sum(Hits) as sh from xhad_month where AD_ID=".$AD_ID." and CurYear='".$y."'";
$exec = mysql_query($sql,$conn);
if($rs = mysql_fetch_array($exec))
{
$sv = $rs["sv"];
$sh = $rs["sh"];
}
?>
<!--------月统计------------->
<table width="100%" border="0" align="center" cellpadding="3" cellspacing="5" bgcolor="#E1F0FF" id="table1">
<tr bgcolor="#DDDDFF">
<td width="10%">月份</td>
<td>显示次数</td>
<td width="200">比例</td>
<td>点击次数</td>
<td width="200">比例</td>
</tr>
<?php
$sql = "select * from xhad_month where AD_ID=".$AD_ID." and CurYear='".$y."' order by ID desc";
$exec = mysql_query($sql,$conn);
while($rs = mysql_fetch_array($exec)){
?>
<tr>
<td><?php echo $rs["CurMonth"]?></td>
<td><?php echo $rs["Views"]?></td>
<td><img src="Images/bar1.gif" height="10" width="<?php echo empty($sv) ? 0 : 200*round($rs["Views"]/$sv,3)?>" align="middle"><?php echo empty($sv) ? 0 : (round($rs["Views"]/$sv,3)*100)."%"?></td>
<td><?php echo $rs["Hits"]?></td>
<td><img src="Images/bar1.gif" height="10" width="<?php echo empty($sh) ? 0 : 200*round($rs["Hits"]/$sh,3)?>" align="middle"><?php echo empty($sh) ? 0 : (round($rs["Hits"]/$sh,3)*100)."%"?></td>
</tr>
<?php }?>
</table>
<!--------月统计结束---------->
<?php }else if($XHType=="d"){?>
<?php
$sql = "select sum(Views) as sv,sum(Hits) as sh from xhad_day where AD_ID=".$AD_ID." and CurYear='".$y."' and CurMonth='".$m."'";
$exec = mysql_query($sql,$conn);
if($rs = mysql_fetch_array($exec))
{
$sv = $rs["sv"];
$sh = $rs["sh"];
}
?>
<!--------日统计------------->
<table width="100%" border="0" align="center" cellpadding="3" cellspacing="5" bgcolor="#E1F0FF" id="table1">
<tr bgcolor="#DDDDFF">
<td width="10%">日期</td>
<td>显示次数</td>
<td width="200">比例</td>
<td>点击次数</td>
<td width="200">比例</td>
</tr>
<?php
$sql = "select * from xhad_day where AD_ID=".$AD_ID." and CurYear='".$y."' and CurMonth='".$m."' order by ID desc";
$exec = mysql_query($sql,$conn);
while($rs = mysql_fetch_array($exec)){
?>
<tr>
<td><?php echo $rs["CurDay"]?></td>
<td><?php echo $rs["Views"]?></td>
<td><img src="Images/bar1.gif" height="10" width="<?php echo empty($sv) ? 0 : 200*round($rs["Views"]/$sv,3)?>" align="middle"><?php echo empty($sv) ? 0 : (round($rs["Views"]/$sv,3)*100)."%"?></td>
<td><?php echo $rs["Hits"]?></td>
<td><img src="Images/bar1.gif" height="10" width="<?php echo empty($sh) ? 0 : 200*round($rs["Hits"]/$sh,3)?>" align="middle"><?php echo empty($sh) ? 0 : (round($rs["Hits"]/$sh,3)*100)."%"?></td>
</tr>
<?php }?>
</table>
<!--------日统计结束---------->
<?php }else if($XHType=="h"){?>
<?php
$sql = "select sum(Views)
没有合适的资源?快使用搜索试试~ 我知道了~
雪晖PHP广告管理系统XHAD (utf-8).zip
共52个文件
php:33个
swf:7个
jpg:6个
0 下载量 151 浏览量
2024-01-25
21:57:03
上传
评论
收藏 590KB ZIP 举报
温馨提示
雪晖PHP广告管理系统XHAD (utf-8).zip
资源推荐
资源详情
资源评论
收起资源包目录
雪晖PHP广告管理系统XHAD (utf-8).zip (52个子文件)
132678318558074148
xhad
TypeStat.php 6KB
Manage
Main.php 838B
Manage_Index.php 567B
Login.php 3KB
Admin_AD.php 8KB
Manage_ADList.php 4KB
Left.php 1KB
Index.php 37B
Include
Function.php 9KB
FileUploader.php 8KB
CheckAdminLogin.php 81B
VerifyCode.php 3KB
CheckUserLogin.php 81B
Conn.php 511B
Admin
Admin_System.php 3KB
Admin_AdType.php 2KB
Main.php 994B
ADTypeCode.php 488B
Login.php 3KB
Admin_Biz.php 4KB
Admin_AD.php 8KB
Admin_Admin.php 3KB
Admin_AdTypeList.php 5KB
Admin_BizList.php 5KB
ADCode.php 481B
Left.php 3KB
Admin_Index.php 574B
Admin_ADList.php 6KB
Index.php 37B
Upfiles
b80a78fc5f193dc3b94fe2d9a48615b7.gif 58KB
93f38b89f6f83716733d8f693f576d1c.jpg 65KB
a290b51b729a0afdb858f88876cd2ea1.swf 24KB
737f03c183f59e1a417fccfad084cf1c.swf 24KB
96f95370549690850fdf7e8e008a3e3e.jpg 60KB
8a1c4b77ece08ca7cce510284f860b90.jpg 65KB
46a937fee8c0c068163c8993071aa91a.jpg 37KB
2d455329c2909d60b89f8a591a1198a7.swf 24KB
e066b6ca318dd8596f04b1271c3c8cd3.jpg 49KB
33eccc8c413412259bc33a8bd626d091.swf 24KB
56b38e101198c0a9c8871b61a99e0b3d.gif 2KB
58322ab754a7f7514b68c676da589458.swf 24KB
ed7bc94de077d882f3c27fd131083721.jpg 41KB
b2ccbd5811c00528cb9ce2c23085e30f.swf 24KB
Css
Css.css 2KB
Report.php 9KB
Stat.php 5KB
test.php 30B
Images
1188819208434.swf 24KB
kong.gif 58B
bar1.gif 84B
Reurl.php 6KB
test.html 212B
共 52 条
- 1
资源评论
快乐无限出发
- 粉丝: 1135
- 资源: 7274
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
- 1_1、_NET Core 基础理论.vep
- 2_2、源码编译与解读(难度大,可最后看).vep
- (Linux环境下C语言)学生管理系统
- 基于STM32F103单片机(寄存器版)+OV7725摄像头模块照相机实验实验例程源码.zip
- 基于Python实现的桥梁易损性分析源码+代码注释.zip
- 基于python开发使用深度学习去预测股票后续的价格+源码+文档(毕业设计&课程设计&项目开发)
- flowable-designer-5.22.0.zip
- threadmanager.cpp
- 腾讯云小程序 - 一站式开发与部署平台
- 基于JSP+Java+Servlet采用MVC模式开发的购物网站+源码(毕业设计&课程设计&项目开发)
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功