<%@language=vbscript codepage=936 %>
<%
'option explicit
response.buffer = True
Response.Expires = -1
Response.ExpiresAbsolute = Now() - 1
Response.Expires = 0
Response.CacheControl = "no-cache"
dim dns
dns="../"
%>
<!--#Include file="../Common/Inc_DatConn.asp"-->
<!--#Include file="Common/Inc_Config.asp"-->
<!--#Include file="Common/Inc_Function.asp"-->
<%
Dim ComeUrl,FoundErr,Errmsg
Dim SQL,Rs,i

if IsTimeOut(Session("strAccount"),Session("strPassWord"))=True then
    Call admin_login()
End if
select case request("action")
case "admin_left"
	call admin_left()
case "admin_login"
	call admin_login()
case "admin_main"
	call admin_main()
case "admin_top"
	call admin_top()
case Else
	call main()
end Select
CloseAllObj
Sub main()
%>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
</head>
<frameset framespacing="0" border="false" rows="32,*" frameborder="0" scrolling="no">
	<frame name="top" scrolling="no" noresize="noresize" src="Admin_Index.asp?Action=admin_top" target="main">
	<frameset id="frame" framespacing="0" border="false" cols="180,*" frameborder="0" scrolling="no">
		<frame name="left" noresize="noresize" marginwidth="0" marginheight="0" src="Admin_Index.asp?Action=admin_left" target="main">
		<frame name="main" scrolling="auto" src="Admin_Index.asp?Action=admin_main" target="main">
	</frameset>
</frameset><noframes></noframes>
</html>
<%
End Sub

Sub admin_left()
	Dim SQL
	Dim ModuleID,sModuleName,sChannelName
	Dim IsCreateHtml
%>
<html>
<head>
<title>管理导航</title>
<style type=text/css>
body  { background:#0096CE; margin:0px; font:normal 12px 宋体; 
SCROLLBAR-FACE-COLOR: #0096CE; SCROLLBAR-HIGHLIGHT-COLOR: #ffffff; 
SCROLLBAR-SHADOW-COLOR: #0096CE; SCROLLBAR-DARKSHADOW-COLOR: #0096CE; 
SCROLLBAR-3DLIGHT-COLOR: #0096CE; SCROLLBAR-ARROW-COLOR: #def0fa;
SCROLLBAR-TRACK-COLOR: #def0fa;
}
table  { border:0px; }
td  { font:normal 12px 宋体; }
img  { vertical-align:bottom; border:0px; }
a  { font:normal 12px 宋体; color:#000000; text-decoration:none; }
a:hover  { color:#428EFF;text-decoration:underline; }
.sec_menu  { border-left:1px solid white; border-right:1px solid white; border-bottom:1px solid white; overflow:hidden; background:#def0fa; }
.menu_title span  { position:relative; top:2px; left:8px; color:#215DC6; font-weight:bold; }
.menu_title2 span  { position:relative; top:2px; left:8px; color:#428EFF; font-weight:bold; }
.tdbg{ background:#def0fa; padding:0 3px; height:22;}
</style>
<SCRIPT language=Javascript>
function showsubmenu(sid)
{
var whichEl = document.getElementById("submenu" + sid);
var imageId = document.getElementById("imgMenu" + sid)
if (whichEl.style.display == "none")
{
whichEl.style.display="";
imageId.src="Images/close.gif";
}
else
{
whichEl.style.display="none"
imageId.src="Images/open.gif";
}
}
</SCRIPT>
</head>
<BODY class="bgleft">
<table width="100%" cellpadding=0 cellspacing=0 border=0 align=left>
    <tr><td valign=top>
<table width=158 border="0" align=center cellpadding=0 cellspacing=0>
  <tr>
    <td height=38 valign=bottom>
	  <img src="Images/title.gif" width=158 height=38>
    </td>
  </tr>
</table>
<table cellpadding=0 cellspacing=0 width=158 align=center>
  <tr>
        <td height=25 class=menu_title onmouseover=this.className='menu_title2'; onmouseout=this.className='menu_title'; background="Images/title_bg_quit.gif" id=menuTitle0> 
          <span><a href="Admin_Index.asp?Action=admin_main" target=main><b>管理首页</b></a> | <a href=LogOut.asp target=_top><b>退出</b></a></span> 
        </td>
  </tr>
  <tr>
    <td style="display:" id='submenu0'>
<div class=sec_menu style="width:158">
<table cellpadding=0 cellspacing=0 align=center width=135>
<tr><td height=20>管理员：<%=Session("strAccount")%></td></tr>
</table>
</div>
<div  style="width:158">
<table cellpadding=0 cellspacing=0 align=center width=135>
<tr><td height=15></td></tr>
</table>
</div>
	</td>
  </tr>
</table>
<%if fla10=1 or fla11=1 or Session("intUserLevel") > 2 then%>
<table cellpadding=0 cellspacing=0 width=158 align=center>
  <tr width="100%">
		<td height=25 class=menu_title onmouseover=this.className='menu_title2'; onmouseout=this.className='menu_title'; background="Images/admin_left.gif" onClick="showsubmenu(4)" style="cursor:hand;"><span><img src="Images/open.gif" style="float:left;margin:2 5 0px;" id="imgMenu4" align="absmiddle">供求信息管理</span></td>
  </tr>
  <tr>
    <td colspan=3 style="width:100%" id="submenu4">
		<table class=sec_menu cellpadding=0 cellspacing=1 align=center width="100%">
<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="info.asp?bbaction=addinfo" target=main><font color="#FF0000">添加新信息</font></a></td></tr><tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="info.asp" target=main>信息管理首页</a></td></tr>
			<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="info.asp?strstate=1" target=main>已审供求信息</a></td></tr>
<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="info.asp?strstate=0" target=main>未审供求信息</a></td></tr>
<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="info.asp?bbaction=guoqi" target=main>过期供求信息</a></td></tr>
		</table>
		<table cellpadding=0 cellspacing=0 align=center width="100%">
			<tr><td height=15></td></tr>
		</table>
	</td>
  </tr>
</table>

<%end if
if fla1=1 or fla2=1 or fla3=1 or fla4=1 or fla5=1 or Session("intUserLevel") > 2 then%>
<table cellpadding=0 cellspacing=0 width=158 align=center>
  <tr width="100%">
		<td height=25 class=menu_title onmouseover=this.className='menu_title2'; onmouseout=this.className='menu_title'; background="Images/admin_left.gif" onClick="showsubmenu(2)" style="cursor:hand;"><span><img src="Images/open.gif" style="float:left;margin:2 5 0px;" id="imgMenu2" align="absmiddle">网站会员管理</span></td>
  </tr>
  <tr>
		<td colspan=3 style="width:100%;display:none" id="submenu2">
		<table class=sec_menu cellpadding=0 cellspacing=1 align=center width="100%">
			<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="user.asp" target=main>会员管理首页</a></td></tr>
            <tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="user.asp?lx=1" target=main>个人会员管理</a></td></tr>
            <tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="user.asp?lx=2" target=main>企业会员管理</a></td></tr>
            </table>
		<table cellpadding=0 cellspacing=0 align=center width="100%">
			<tr><td height=15></td></tr>
		</table>
	</td>
  </tr>
</table>
<%end if
if fla6=1 or fla7=1 or fla8=1 or fla9=1 or Session("intUserLevel") > 2 then%>
<table cellpadding=0 cellspacing=0 width=158 align=center>
  <tr width="100%">
		<td height=25 class=menu_title onmouseover=this.className='menu_title2'; onmouseout=this.className='menu_title'; background="Images/admin_left.gif" onClick="showsubmenu(3)" style="cursor:hand;"><span><img src="Images/open.gif" style="float:left;margin:2 5 0px;" id="imgMenu3" align="absmiddle">行业新闻管理</span></td>
  </tr>
  <tr>
    <td colspan=3 style="width:100%;display:none" id="submenu3">
		<table class=sec_menu cellpadding=0 cellspacing=1 align=center width="100%">
<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="news.asp?bbaction=addnews" target="main">添加行业新闻</a></td></tr>
		<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="news.asp" target="main">行业新闻管理</a></td></tr>
            <tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="news.asp?strstata=1" target=main>已审行业新闻</a></td></tr>
<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="news.asp?strstata=0" target=main>未审行业新闻</a></td></tr>
		</table>
		<table cellpadding=0 cellspacing=0 align=center width="100%">
			<tr><td height=15></td></tr>
		</table>
	</td>
  </tr>
</table>
<%end if
if fla18=1 or fla19=1 or fla20=1 or Session("intUserLevel") > 2 then%>
<table cellpadding=0 cellspacing=0 width=158 align=center>
  <tr width="100%">
		<td height=25 class=menu_title onmouseover=this.className='menu_title2'; onmouseout=this.className='menu_title'; background="Images/admin_left.gif" onClick="showsubmenu(5)" style="cursor:hand;"><span><img src="Images/open.gif" style="float:left;margin:2 5 0px;" id="imgMenu5" align="absmiddle">网站分类管理</span></td>
  </tr>
  <tr>
    <td colspan=3 style="width:100%;display:none" id="submenu5">
		<table class=sec_menu cellpadding=0 cellspacing=1 align=center width="100%">
			<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="infoclass.asp" target=main>信息分类管理</a></td></tr>
            <tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="addclass.asp" target=main>地区分类管理</a></td></tr>
<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="hyclass.asp" target=main>黄页分类管理</a></td></tr>
		</table>
		<table cellpadding=0 cellspacing=0 align=center width="100%">
			<tr><td height=15></td></tr>
		</table>
	</td>
  </tr>
</table>
<%end if
if fla21=1 or Session("intUserLevel") > 2 then%>
<table cellpadding=0 cellspacing=0 width=158 align=center>
  <tr width="100%">
		<td height=25 class=menu_title onmouseover=this.className='menu_title2'; onmouseout=this.className='menu_title'; background="Images/admin_left.gif" onClick="showsubmenu(6)" style="cursor:hand;"><span><img src="Images/open.gif" style="float:left;margin:2 5 0px;" id="imgMenu6" align="absmiddle">反馈信息管理</span></td>
  </tr>
  <tr>
    <td colspan=3 style="width:100%;display:none" id="submenu6">
		<table class=sec_menu cellpadding=0 cellspacing=1 align=center width="100%">
		<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="guestbook.asp" target=main>反馈信息管理</a></td></tr>
		</table>
		<table cellpadding=0 cellspacing=0 align=center width="100%">
			<tr><td height=15></td></tr>
		</table>
	</td>
  </tr>
</table>
<%end if
if fla22=1 or Session("intUserLevel") > 2 then%>
<table cellpadding=0 cellspacing=0 width=158 align=center>
  <tr width="100%">
		<td height=25 class=menu_title onmouseover=this.className='menu_title2'; onmouseout=this.className='menu_title'; background="Images/admin_left.gif" onClick="showsubmenu(7)" style="cursor:hand;"><span><img src="Images/open.gif" style="float:left;margin:2 5 0px;" id="imgMenu7" align="absmiddle">热门商家管理</span></td>
		 <td class="divMTitRi fRig"></td>
  </tr>
  <tr>
    <td colspan=3 style="width:100%;display:none" id="submenu7">
		<table class=sec_menu cellpadding=0 cellspacing=1 align=center width="100%">
			<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="link.asp" target="main">热门商家管理</a></td></tr>
			<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="link.asp?strstata=0" target="main">热门商家审核</a></td></tr>
		</table>
		<table cellpadding=0 cellspacing=0 align=center width="100%">
			<tr><td height=15></td></tr>
		</table>
	</td>
  </tr>
</table>
<%end if
if fla24=1 or Session("intUserLevel") > 2 then%>
<table cellpadding=0 cellspacing=0 width=158 align=center>
  <tr width="100%">
		<td height=25 class=menu_title onmouseover=this.className='menu_title2'; onmouseout=this.className='menu_title'; background="Images/admin_left.gif" onClick="showsubmenu(8)" style="cursor:hand;"><span><img src="Images/open.gif" style="float:left;margin:2 5 0px;" id="imgMenu8" align="absmiddle">使用说明管理</span></td>
  </tr>
  <tr>
    <td colspan=3 style="width:100%;display:none" id="submenu8">
		<table class=sec_menu cellpadding=0 cellspacing=1 align=center width="100%">
		<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="gsjj.asp" target=main>使用说明管理</a></td></tr>
		</table>
		<table cellpadding=0 cellspacing=0 align=center width="100%">
			<tr><td height=15></td></tr>
		</table>
	</td>
  </tr>
</table>
<%end if
if fla25=1 or Session("intUserLevel") > 2 then%>
<table cellpadding=0 cellspacing=0 width=158 align=center>
  <tr width="100%">
		<td height=25 class=menu_title onmouseover=this.className='menu_title2'; onmouseout=this.className='menu_title'; background="Images/admin_left.gif" onClick="showsubmenu(9)" style="cursor:hand;"><span><img src="Images/open.gif" style="float:left;margin:2 5 0px;" id="imgMenu9" align="absmiddle">联系方式管理</span></td>
  </tr>
  <tr>
    <td colspan=3 style="width:100%;display:none" id="submenu9">
		<table class=sec_menu cellpadding=0 cellspacing=1 align=center width="100%">
		<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="lxwm.asp" target=main>联系方式管理</a></td></tr>
		</table>
		<table cellpadding=0 cellspacing=0 align=center width="100%">
			<tr><td height=15></td></tr>
		</table>
	</td>
  </tr>
</table>
<%
end if
if fla27=1 or Session("intUserLevel") > 2 then%>
<table cellpadding=0 cellspacing=0 width=158 align=center>
  <tr width="100%">
		<td height=25 class=menu_title onmouseover=this.className='menu_title2'; onmouseout=this.className='menu_title'; background="Images/admin_left.gif" onClick="showsubmenu(10)" style="cursor:hand;"><span><img src="Images/open.gif" style="float:left;margin:2 5 0px;" id="imgMenu10" align="absmiddle">网站广告管理</span></td>
  </tr>
  <tr>
    <td colspan=3 style="width:100%;display:none" id="submenu10">
		<table class=sec_menu cellpadding=0 cellspacing=1 align=center width="100%">
<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="ad.asp" target=main>广告管理首页</a></td></tr>
<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="ad.asp?action=stop" target=main>过期广告管理</a></td></tr>
<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="ad.asp?bbaction=add" target=main>添加新广告</a></td></tr>
		<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="ad.asp?bbaction=code" target=main>使用说明</a></td></tr>
		</table>
		<table cellpadding=0 cellspacing=0 align=center width="100%">
			<tr><td height=15></td></tr>
		</table>
	</td>
  </tr>
</table>
<%end if
if Session("intUserLevel") > 2 then%>

<table cellpadding=0 cellspacing=0 width=158 align=center>
  <tr width="100%">
		<td height=25 class=menu_title onmouseover=this.className='menu_title2'; onmouseout=this.className='menu_title'; background="Images/admin_left.gif" onClick="showsubmenu(100)" style="cursor:hand;"><span><img src="Images/open.gif" style="float:left;margin:2 5 0px;" id="imgMenu10" align="absmiddle">网站系统管理</span></td>
  </tr>
  <tr>
    <td colspan=3 style="width:100%;display:none" id="submenu100">
		<table class=sec_menu cellpadding=0 cellspacing=1 align=center width="100%">
<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="sysconfig.asp" target=main>网站参数设置</a></td></tr>
<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="sysuser.asp" target=main>管理员管理</a></td></tr>
<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="iplock.asp" target=main>IP 限制管理</a></td></tr>
		<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="Admin_Data.asp?Action=Backup" target=main>备份数据库</a></td></tr>
		<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="Admin_Data.asp?Action=Restore" target=main>恢复数据库</a></td></tr>
		<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="Admin_Data.asp?Action=Compact" target=main>压缩数据库</a></td></tr>
		<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="Admin_Data.asp?Action=ServerInfo" target=main>服务器信息</a></td></tr>
		<tr class="tdbg"><td height=20>&nbsp;&nbsp;<a href="Admin_Data.asp?Action=SpaceSize" target=main>系统空间占用</a></td></tr>
		</table>
		<table cellpadding=0 cellspacing=0 align=center width="100%">
			<tr><td height=15></td></tr>
		</table>
	</td>
  </tr>
</table>
<%end if%>
<table cellpadding=0 cellspacing=0 width=158 align=center>
  <tr width="100%">
		<td height=25 class=menu_title onmouseover=this.className='menu_title2'; onmouseout=this.className='menu_title'; background="Images/admin_left.gif" onClick="showsubmenu(11)" style="cursor:hand;"><span><img src="Images/close.gif" style="float:left;margin:2 5 0px;" id="imgMenu11" align="absmiddle">系统版权信息</span></td>
  </tr>
  <tr>
    <td colspan=3 style="width:170" id="submenu11">
		<table class=sec_menu cellpadding=0 cellspacing=1 align=center width="100%">
		<tr class="tdbg"><td height=20><br>
&nbsp;&nbsp;版权所有：推广宝网络有限公司<br><br></td></tr>
	</table>
	</td>
  </tr>
</table>
</body>
</html>
<%
End Sub

Sub admin_top()
%>
<html>
<head>
<title>后台管理页面</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<style type=text/css>
body  { margin:0px; font:normal 12px 宋体; 
SCROLLBAR-FACE-COLOR: #0096CE; SCROLLBAR-HIGHLIGHT-COLOR: #ffffff; 
SCROLLBAR-SHADOW-COLOR: #0096CE; SCROLLBAR-DARKSHADOW-COLOR: #0096CE; 
SCROLLBAR-3DLIGHT-COLOR: #0096CE; SCROLLBAR-ARROW-COLOR: #def0fa;
SCROLLBAR-TRACK-COLOR: #def0fa;
}
table  { border:0px; }
td  { font:normal 12px 宋体; }
img  { vertical-align:bottom; border:0px; }
a  { font:normal 12px 宋体; color:#000000; text-decoration:none; }
a:hover  { color:#428EFF;text-decoration:underline; }
.sec_menu  { border-left:1px solid white; border-right:1px solid white; border-bottom:1px solid white; overflow:hidden; background:#def0fa; }
.menu_title span  { position:relative; top:2px; left:8px; color:#215DC6; font-weight:bold; }
.menu_title2 span  { position:relative; top:2px; left:8px; color:#428EFF; font-weight:bold; }
th,.title{FONT-WEIGHT: bold; FONT-SIZE: 12px; BACKGROUND-COLOR: #0096CE; Height: 20; COLOR: white; }
.border{BORDER-RIGHT: #0096CE 1px solid; BORDER-TOP: #0096CE 1px solid;
BORDER-LEFT: #0096CE 1px solid; WIDTH: 100%; BORDER-BOTTOM: #0096CE 1px solid; BACKGROUND-COLOR: #ffffff}
</style>
<base target="main">
<script src="images/Admin.js" Language="JavaScript"></Script>
<script language="JavaScript" type="text/javascript">
var displayBar=true;
function switchBar(obj)
{
	if (displayBar)
	{
		parent.frame.cols="0,*";
		displayBar=false;
		obj.src="Images/admin_top_open.gif";
		obj.title="打开左边管理菜单";
	}
	else{
		parent.frame.cols="180,*";
		displayBar=true;
		obj.src="Images/admin_top_close.gif";
		obj.title="关闭左边管理菜单";
	}
}
function Goto(url)
{
	parent.main.location.href=url;
}
function UGoto(url)
{
	parent.location.href=url;
}
</script>
</head>
<body leftmargin="0" topmargin="0">
<table width="100%" border=0 cellpadding=0 cellspacing=1 class="border">
<tr class=title><td>
<table width="100%" border=0 cellpadding=0 cellspacing=0>
<tr valign=middle>
	<td width=30><img src="../Images/0101.gif" style="cursor:hand">
	</td><td width=30><img onClick="switchBar(this)" src="Images/admin_top_close.gif" title="关闭左边管理菜单" style="cursor:hand" width=28 height=26>
	</td>
	<td height=28 width="800" align=right>
		<a onClick="Goto('sysconfig.asp')" style="cursor:hand"><b><font color=ffff00>系统配置</font></b></a>&nbsp;
		<a onClick="Goto('info.asp')" style="cursor:hand"><b><font color=blue>信息管理</font></b></a>&nbsp;
		<a onClick="Goto('user.asp')" style="cursor:hand"><b><font color=#ffffff>会员管理</font></b></a>&nbsp;
		<a onClick="Goto('news.Asp')" style="cursor:hand"><b><font color=#ffffff>行业新闻</font></b></a>&nbsp;
		<a onClick="Goto('Admin_Index.asp?action=admin_main')" style="cursor:hand"><b><font color=#ffffff>管理首页</font></b></a>&nbsp;
		<a onClick="UGoto('Logout.asp')" style="cursor:hand"><b><font color=#ffffff>退出后台</font></b></a>
	</td>
	<td width=30>　</td>
</tr>
</table>
</td>
</tr>
</table>

</body>
</html>
<%
End Sub

Sub admin_main()
Dim theInstalledObjects(20)
theInstalledObjects(0) = "MSWC.AdRotator"
theInstalledObjects(1) = "MSWC.BrowserType"
theInstalledObjects(2) = "MSWC.NextLink"
theInstalledObjects(3) = "MSWC.Tools"
theInstalledObjects(4) = "MSWC.Status"
theInstalledObjects(5) = "MSWC.Counters"
theInstalledObjects(6) = "IISSample.ContentRotator"
theInstalledObjects(7) = "IISSample.PageCounter"
theInstalledObjects(8) = "MSWC.PermissionChecker"
theInstalledObjects(9) = "Scripting.FileSystemObject"
theInstalledObjects(10) = "adodb.Connection"
theInstalledObjects(11) = "SoftArtisans.FileUp"
theInstalledObjects(12) = "SoftArtisans.FileManager"
theInstalledObjects(13) = "JMail.SMTPMail"
theInstalledObjects(14) = "CDONTS.NewMail"
theInstalledObjects(15) = "Persits.MailSender"
theInstalledObjects(16) = "LyfUpload.UploadFile"
theInstalledObjects(17) = "Persits.Upload.1"
theInstalledObjects(18) = "Adodb." & "Str" & "eam"
theInstalledObjects(19) = "Microsoft.XMLHTTP"
theInstalledObjects(20) = "JMail.SmtpMail"

%>
<html>
<head>
<title>后台管理首页</title>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link rel="stylesheet" href="images/Admin_Style.Css">
</head>
<body leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">
<table cellpadding="2" cellspacing="1" border="0" class="border" align=center>
  <tr align="center"> 
    <td height=25 colspan=2 class="title"><strong>服 务 器 信 息 检 测</strong></tr>
  <tr class="tdbg"><td class="title2" height=23 colspan=2>欢迎光临</td></tr>
  <tr class="tdbg"> 
    <td width="50%" height=23>服务器类型：<%=GetSysOS%></td>
    <td width="50%">脚本解释引擎：<%=ScriptEngine & "/"& ScriptEngineMajorVersion &"."&ScriptEngineMinorVersion&"."& ScriptEngineBuildVersion %></td>
  </tr>
  <tr class="tdbg">
    <td width="50%" height=23>服务器端口：<%=Request.ServerVariables("SERVER_PORT")%>&nbsp;&nbsp;IP：<%=Request.ServerVariables("LOCAL_ADDR")%></td>
    <td width="50%" height=23>服务器IIS版本：<%=Request.ServerVariables("SERVER_SOFTWARE")%></td>
  </tr>
  <tr align="center"> 
    <td height=25 colspan=2 class="title"><strong>服 务 器 组 件 检 测(管理系统将用到以下组件)</strong></tr>
  <tr class="tdbg"> 
    <td width="50%">数据库使用：
      <%If Not IsObjInstalled(theInstalledObjects(10)) Then%>
      <font color="red"><b>×</b></font>
      <%else%>
      <font color=green><b>√</b></font>
      <%end if%></td>
    <td width="50%" height=23>AspJpeg生成预览图片：
      <%If Not IsObjInstalled("Persits.Jpeg") Then%>
      <font color="red"><b>×</b></font>
      <%else%>
      <font color=green><b>√</b></font>
      <%end if%></td>
  </tr>
  <tr class="tdbg"> 
    <td width="50%">Microsoft.XMLHTTP：
      <%If Not IsObjInstalled(theInstalledObjects(19)) Then%>
      <font color="red"><b>×</b></font>
      <%else%>
      <font color=green><b>√</b></font>
      <%end if%></td>
    <td width="50%" height=23>Jmail邮件发送：
      <%If Not IsObjInstalled(theInstalledObjects(20)) Then%>
      <font color="red"><b>×</b></font>
      <%else%>
      <font color=green><b>√</b></font>
      <%end if%></td>
  </tr>
  <tr class="tdbg">
    <td width="50%" height=23>FSO文本读写：
      <%If Not IsObjInstalled(theInstalledObjects(9)) Then%>
      <font color="red"><b>×</b></font>
      <%else%>
      <font color=green><b>√</b></font>
      <%end if%></td>
    <td width="50%">无组件上传：
      <%If Not IsObjInstalled(theInstalledObjects(18)) Then%>
      <font color="red"><b>×</b></font>
      <%else%>
      <font color=green><b>√</b></font>
      <%end if%>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="Admin_Data.asp?Action=ServerInfo">查看更详细的服务器信息&gt;&gt;&gt;</a></td>
  </tr>
</table>
<br>
<%
Dim rdsMember
Dim intAllMemberCot

Dim rdsNews
Dim intAllNewsCot,intAllEaaNewsCot,intAllPubNewsCot

Dim rdsInfo
Dim intAllInfoCot,intAllEaaInfoCot,intAllPubInfoCot

Dim rdsFeedBack
Dim intAllFeedBackCot,intAllNewFeedBackCot

set rdsMember = Server.CreateObject("ADODB.Recordset")
rdsMember.Open "Select Count(*) As AllMemberCot From Dat_Member",Conn
if not rdsMember.EOF then
	intAllMemberCot = rdsMember("AllMemberCot")
else
	intAllMemberCot = 0
end if
rdsMember.Close

set rdsNews = Server.CreateObject("ADODB.Recordset")
rdsNews.Open "Select Count(*) As AllNewsCot From Dat_News",Conn
if not rdsNews.EOF then
	intAllNewsCot = rdsNews("AllNewsCot")
else
	intAllNewsCot = 0
end if
rdsNews.Close

rdsNews.Open "Select Count(*) As AllEaaNewsCot From Dat_News Where State = 0",Conn
if not rdsNews.EOF then
	intAllEaaNewsCot = rdsNews("AllEaaNewsCot")
else
	intAllEaaNewsCot = 0
end if
rdsNews.Close

rdsNews.Open "Select Count(*) As AllPubNewsCot From Dat_News Where State = 1",Conn
if not rdsNews.EOF then
	intAllPubNewsCot = rdsNews("AllPubNewsCot")
else
	intAllPubNewsCot = 0
end if
rdsNews.Close
set rdsNews = nothing

set rdsInfo = Server.CreateObject("ADODB.Recordset")
rdsInfo.Open "Select Count(*) As AllInfoCot From Dat_Information",Conn
if not rdsInfo.EOF then
	intAllInfoCot = rdsInfo("AllInfoCot")
else
	intAllInfoCot = 0
end if
rdsInfo.Close

rdsInfo.Open "Select Count(*) As AllEaaInfoCot From Dat_Information Where State = 0",Conn
if not rdsInfo.EOF then
	intAllEaaInfoCot = rdsInfo("AllEaaInfoCot")
else
	intAllEaaInfoCot = 0
end if
rdsInfo.Close

rdsInfo.Open "Select Count(*) As AllPubInfoCot From Dat_Information Where State = 1",Conn
if not rdsInfo.EOF then
	intAllPubInfoCot = rdsInfo("AllPubInfoCot")
else
	intAllPubInfoCot = 0
end if
rdsInfo.Close
set rdsInfo = nothing

set rdsFeedBack = Server.CreateObject("ADODB.Recordset")
rdsFeedBack.Open "Select Count(*) As AllFeedBackCot From Dat_FeedBack",Conn
if not rdsFeedBack.EOF then
	intAllFeedBackCot = rdsFeedBack("AllFeedBackCot")
else
	intAllFeedBackCot = 0
end if
rdsFeedBack.Close

rdsFeedBack.Open "Select Count(*) As AllNewFeedBackCot From Dat_FeedBack Where State = 0",Conn
if not rdsFeedBack.EOF then
	intAllNewFeedBackCot = rdsFeedBack("AllNewFeedBackCot")
else
	intAllNewFeedBackCot = 0
end if
rdsFeedBack.Close
set rdsFeedBack = nothing
%>
<table cellpadding="2" cellspacing="1" border="0" class="border" align=center>
  <tr>
    <td colspan="2" class="title">信息统计</td>
  </tr>
  <tr>
    <td width="15%" align="right" class="tdbg"><strong>供求信息</strong>：</td>
    <td align="left" class="tdbg">当前系统中共有信息数：<font color="#FF0000"><b><%=intAllInfoCot%></b></font>个（其中已发布：<font color="#FF0000"><b><%=intAllPubInfoCot%></b></font>个，未审批的：<font color="#FF0000"><b><%=intAllEaaInfoCot%></b></font>个）</td>
  </tr>
  <tr>
    <td width="15%" align="right" class="tdbg"><strong>网站会员</strong>：</td>
    <td align="left" class="tdbg">当前网站共有注册会员：<font color="#FF0000"><b><% = intAllMemberCot%></b></font>名</td>
  </tr>
    <tr>
    <td width="15%" align="right" class="tdbg"><strong>行业新闻</strong>：</td>
    <td align="left" class="tdbg">当前系统中共有新闻数：<font color="#FF0000"><b><% = intAllNewsCot%></b></font>条（其中已发布：<font color="#FF0000"><b><% = intAllPubNewsCot%></b></font>条，未审批的：<font color="#FF0000"><b><% = intAllEaaNewsCot%></b></font>条）</td>
  </tr>
    <tr>
    <td width="15%" align="right" class="tdbg"><strong>举报反馈</strong>：</td>
    <td align="left" class="tdbg">当前系统中共有信息：<font color="#FF0000"><b><%=intAllFeedBackCot%></b></font>条（其中新信息：<font color="#FF0000"><b><%=intAllNewFeedBackCot%></b></font>条）</td>
  </tr>
    </table>
<br>
<table cellpadding="2" cellspacing="1" border="0" class="border" align=center>
  <tr>
    <td colspan="2" class="title">推广宝信息发布平台</td>
  </tr>
  <tr>
    <td width="15%" align="right" class="tdbg"><strong>产品开发</strong>：</td>
    <td align="left" class="tdbg">&nbsp;推广宝信息发布平台</td>
  </tr>
  <tr>
    <td width="15%" align="right" class="tdbg"><strong>服务QQ</strong>：</td>
    <td align="left" class="tdbg">&nbsp;123634878</td>
  </tr>
  <tr>
    <td width="15%" align="right" class="tdbg"><strong>官方网站</strong>：</td>
    <td align="left" class="tdbg">&nbsp;<a href="http://www.tgb.cc" target="_blank">http://www.tgb.cc</a>&nbsp;&nbsp;</td>
  </tr>
</table>
<p align="Center">
  Copyright (c) 2004-2011 <a href="http://www.tgb.cc" target="_blank"><font Arial, Helvetica, sans-serif>www.tgb.cc</font></a> .All Rights Reserved.<BR>
</p>
</body>
</html>
<%
End Sub

Sub admin_login()
	If request("reaction")="chklogin" then
		Call chklogin()
else
Call admin_login_main()
	End If
End Sub

Sub admin_login_main()
%>
<HTML><HEAD><TITLE><%=strSiteName%></TITLE>
<META http-equiv=Content-Language content=zh-cn>
<META http-equiv=Content-Type content="text/html; charset=gb2312">
<META content="MSHTML 6.00.2800.1106" name=GENERATOR>
<META content=FrontPage.Editor.Document name=ProgId>
<script language=javascript>
<!--
function CheckForm()
{
	if(document.Login.UserName.value=="")
	{
		alert("请输入用户名！");
		document.Login.UserName.focus();
		return false;
	}
	if(document.Login.Password.value == "")
	{
		alert("请输入密码！");
		document.Login.Password.focus();
		return false;
	}
	if (document.Login.VerifyCode.value==""){
       alert ("请输入您的验证码！");
       document.Login.VerifyCode.focus();
       return(false);
    }
}
//-->
</script>
<style type="text/css">
<!--
body,td,th {font-size: 12px;}
Input{FONT-SIZE: 12px;}
.stylefont{font-size:12px;COLOR:weight: bold;}
-->
</style>
</HEAD>
<BODY bgColor=#ffffff leftMargin=0 topMargin=0>
<TABLE height="100%" cellSpacing=0 cellPadding=0 width="100%" bgColor=#ffffff border=0> 
  <TBODY>
<FORM name=Login action=admin_index.asp?action=admin_login&reaction=chklogin method="post" target="_parent" OnSubmit="return CheckForm()">
  <TR>
    <TD vAlign=center noWrap align=middle width="100%" height="100%">
      <TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
        <TBODY>
        <TR>
          <TD>
            <TABLE height=59 cellSpacing=0 cellPadding=0 width=611 align=center 
            border=0>
              <TBODY>
              <TR>
                <TD width=34 rowSpan=2>
				<IMG height=59 
                  src="../images/top-1.gif" width=34></TD>
                <TD height=15>
				<IMG height=15 
                  src="../images/top-2.gif" width=537></TD>
                <TD width=40 rowSpan=2>
				<IMG height=59 
                  src="../images/top-3.gif" width=40></TD></TR>
              <TR>
                <TD bgColor=#e8e8e8 height=44>
                  <TABLE cellSpacing=0 cellPadding=0 width=537 border=0>
                    <TBODY>
                    <TR>
                      <TD width=537 height=44>推广宝信息发布平台</TD>
                      </TR></TBODY></TABLE></TD></TR></TBODY></TABLE></TD></TR>
        <TR>
          <TD background=../images/cplogin_bg.gif>
            <TABLE height=294 cellSpacing=0 cellPadding=0 width=611 align=center 
            border=0>
              <TBODY>
              <TR>
                <TD vAlign=top width=611 
                background=../images/middle-bg.gif height=294>
                  <TABLE cellSpacing=0 cellPadding=0 width=611 border=0>
                    <TBODY>
                    <TR>
                      <TD width=110 height=52>　</TD>
                      <TD vAlign=bottom width=501 height=52>　</TD></TR></TBODY></TABLE>
                  <TABLE cellSpacing=0 cellPadding=0 width=611 border=0>
                    <TBODY>
                    <TR>
                      <TD colSpan=2 height=28>　</TD></TR>
                    <TR>
                      <TD width=311 height=93>　</TD>
                      <TD vAlign=top width=300 height=93>
                        <TABLE cellSpacing=0 cellPadding=0 width=280 border=0>
                          <TBODY>
                          <TR>
                            <TD style="FONT-SIZE: 12px; COLOR: #ffffff" 
                              width=60 align="right">账&nbsp;&nbsp;号:</TD>
                            <TD width=188><INPUT class=face size=16 name=UserName type=input></TD></TR>
                          <tr>
                            <TD style="FONT-SIZE: 12px; COLOR: #ffffff" 
                              width=60 align="right">密&nbsp;&nbsp;码:</TD>
                            <TD width=188>
							<INPUT class=face type=password size=16 
                        name=Password></TD>
							</tr>
                          <TR>
                            <TD style="FONT-SIZE: 12px; COLOR: #ffffff" 
                              width=60 align="right">验证码:</TD>
                            <TD width=188>
				<INPUT class=face size=4 name=VerifyCode type=input>&nbsp;<% = GetCode() %></TD></TR>
                          </TBODY></TABLE></TD></TR>
                    <TR>
                      <TD width=311 height=25>　</TD>
                      <TD id=login_td align=middle width=300 height=25>
						<INPUT 
                        type=image src="../images/cplogin_login.gif" 
                        border=0></TD></TR>
                    <TR vAlign=bottom>
                      <TD colSpan=2 height=96>
                        <TABLE cellSpacing=0 cellPadding=0 width=611 border=0>
                          <TBODY>
                          <TR>
                            <TD width=520 height=40>　</TD>
                            <TD width=81></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE></TD></TR></TBODY></TABLE>
      <TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>
        <TBODY>
        <TR>
          <TD>　</TD></TR>
        <TR>
          <TD>　</TD></TR>
        <TR>
          <TD align=middle>
            <TABLE cellSpacing=0 cellPadding=0 width=430 border=0>
              <TBODY>
              <TR>
                <TD width=14 height=25>
				<IMG height=35 
                  src="../images/bottom-left.gif" width=14></TD>
                <TD class=darkgray align=middle 
                background=../images/bottom-bg.gif valign="middle">
				<font color="#FF0000"><b>技术支持：M1955科技有限公司</b></font></TD>
                <TD width=15 height=25>
				<IMG height=35 
                  src="../images/bottom-right.gif" 
              width=15></TD></TR></TBODY></TABLE></TD></TR>
</TBODY></TABLE></TD></TR></FORM></TBODY></TABLE>
</BODY></HTML>
<%
End Sub

Sub chklogin()
session.Timeout =20
UserName =replace(replace(replace(replace(Request.Form("username"),chr(34),"&quot;"),"'",""),chr(13),"")," "," ") 
TempUserPass = replace(replace(replace(replace(Request.Form("Password"),chr(34),"&quot;"),"'",""),chr(13),"")," "," ") 
VerifyCode = replace(replace(replace(replace(Request.Form("VerifyCode"),chr(34),"&quot;"),"'",""),chr(13),"")," "," ") 

if UserName = "" or  TempUserPass = "" then
FoundErr=True
ErrMsg=ErrMsg & "<br><li>错误：请填写完整！</li>"
end if
if  VerifyCode =""  then 
FoundErr=True
ErrMsg=ErrMsg & "<br><li>错误：验证码错误！</li>"
end if
if cint(Session("GetCode"))<>cint(Trim(Request("VerifyCode"))) then 
FoundErr=True
ErrMsg=ErrMsg & "<br><li>错误：验证码错误！</li>"
end if
if request("VerifyCode") = "" then
FoundErr=True
ErrMsg=ErrMsg & "<br><li>错误：请填写验证码！</li>"
elseif Session("GetCode") = "9999" then
	Session("GetCode")=""
elseif Session("GetCode") = "" then
FoundErr=True
ErrMsg=ErrMsg & "<br><li>错误：请不要重复提交，如需重新登录请返回登录页面。返回后请刷新登录页面后重新输入正确的信息！</li>"
elseif cstr(Session("GetCode"))<>cstr(Trim(Request("VerifyCode"))) then
FoundErr=True
ErrMsg=ErrMsg & "<br><li>您输入的确认码和系统产生的不一致，请重新输入。返回后请刷新登录页面后重新输入正确的信息！</li>"
end if
if FoundErr<>True then
'/验证系统用户账户及管理密码/
Dim rdsAccount	'/创建用户账号访问对象/
Dim sqlAccount  '/创建SQL语句/
Dim strAccount	'/用户账号/
Dim strPassWord	'/管理密码/

strAccount =UserName
strPassWord =TempUserPass

set rdsAccount = Server.CreateObject("ADODB.Recordset")
sqlAccount = "Select * From Sys_Account Where Account = '"& strAccount &"'"
rdsAccount.Open sqlAccount,Conn
if not rdsAccount.EOF then
	if md5(TempUserPass,16)= rdsAccount("Password") then
		if rdsAccount("State") = "0" then
			Session("intUserKey") = rdsAccount("UserKey")
			Session("strAccount") = strAccount
			Session("strPassword") = strPassword
			Session("intUserLevel") = rdsAccount("UserLevel")
			Session("strflag") = rdsAccount("flag")
			
			Response.Redirect "Admin_Index.asp"
		else
			FoundErr=True
	        ErrMsg=ErrMsg & "<br><li>对不起！您的管理账号已被禁止登录，请与管理员联系！</li>"
		end if
	else
				FoundErr=True
	        ErrMsg=ErrMsg & "<br><li>您输入的管理密码不正确，请重新输入！</li>"
	end if
else
			FoundErr=True
	        ErrMsg=ErrMsg & "<br><li>您输入的账户不存在，请重新输入！</li>"
end if
rdsAccount.Close
set rdsAccount = nothing
else
	Call ShowErr(ErrMsg)
end if
if FoundErr=True then
Call ShowErr(ErrMsg)
end if
End Sub

'****************************************************
'过程名：ShowErr
'作  用：显示错误提示信息
'参  数：无
'****************************************************
Sub ShowErr(ErrMsg)
	dim strErr
	strErr=strErr & "<html><head><title>错误信息</title><meta http-equiv='Content-Type' content='text/html; charset=gb2312'>" & vbcrlf
	strErr=strErr & "<link href='images/Admin_Style.Css' rel='stylesheet' type='text/css'></head><body>" & vbcrlf
	strErr=strErr & "<table cellpadding=2 cellspacing=1 border=0 width=400 class='border' align=center>" & vbcrlf
	strErr=strErr & "  <tr align='center'><td height='22' class='title'><strong>错误信息</strong></td></tr>" & vbcrlf
	strErr=strErr & "  <tr><td height='100' class='tdbg' valign='top'><b>产生错误的可能原因：</b><br>" & ErrMsg &"</td></tr>" & vbcrlf
	strErr=strErr & "  <tr align='center'><td class='tdbg'><a href='Admin_Index.asp?Action=admin_login'>&lt;&lt; 返回登录页面</a></td></tr>" & vbcrlf
	strErr=strErr & "</table>" & vbcrlf
	strErr=strErr & "</body></html>" & vbcrlf
	response.write strErr
end sub

Function GetSysOS()
  on error resume next
  Dim WshShell,WshSysEnv
  Set WshShell = server.CreateObject("WScr" & "ipt" & "." & "Sh" & "ell")
  Set WshSysEnv = WshShell.Environment("SYSTEM")
  GetSysOS = cstr(WshSysEnv("OS"))
  if Trim(Request.ServerVariables("OS"))="" then GetSysOS=GetSysOS & "(Windows Server 2003)"
End Function
Function GetCode()
	Dim TestObj
	On Error Resume Next
	Set TestObj = Server.CreateObject("Adodb.Stream")
	Set TestObj = Nothing
	If Err Then
		Dim TempNum
		Randomize timer
		TempNum = cint(8999*Rnd+1000)
		Session("GetCode") = TempNum
		GetCode = Session("GetCode")
	Else
		GetCode = "<img src=""../common/GetCode.asp"" onclick='this.src=this.src;' style='cursor:pointer'>"		
	End If
End Function
%>
