  <% 
	data_path="../../" 'ACC连接数据库路径，对SQL无效
	numid="no"
	dir="no" 

Response.Buffer = True 
Response.ExpiresAbsolute = Now() - 1 
Response.Expires = 0 
Response.CacheControl = "no-cache" 
Response.AddHeader "Pragma", "No-Cache" 


  %>
  <!--#include file="../../conn/conn.asp"-->
  <!--#include file="../../inc/safe.asp"-->
<!--#include file="../../inc/FileSystem.asp"-->
<!--#include file="../rolecheck.asp"-->

<link rel="stylesheet" type="text/css" href="../css/style.css">
            <script>
var checkflag="false";
function check(field){
if(checkflag=="false"){
for(i=0;i<field.length;i++){
field[i].checked=true;}
checkflag="true";
return "解除全选"; }
else {
for(i=0;i<field.length;i++) {
field[i].checked=false;}
checkflag="false";
return "选择全部";}}
</script>
<style type="text/css">
<!--
body,td,tr { font-size:12px}
.STYLE2 {font-size: 12px}
-->
 </style>
<body>
<%
if not isempty(request("selAnnounce")) then
	idlist=request("selAnnounce")
	if instr(idlist,",")>0 then
		dim idarr
		idArr=split(idlist)
		dim log_id
		for i = 0 to ubound(idarr)
			log_id=clng(idarr(i))
			call deleteannounce(log_id)
		next
	else
		call deleteannounce(clng(idlist))

	end if
end if

'if request("action")="" then
'response.write "<script language='javascript'>"
'response.write "alert('您提交的信息不符合规范！');"
'response.write"javascript:history.back(-1)<'/SCRIPT>"
'response.end
'end if
 action=request("action")
 keywords=replace_text(request.Form("keywords"))
%>
<%
if action="" then
 sql="select * from websen_post order by id desc"
else
sql="select * from websen_post where "
if action="0" then
  	sql=sql&"flag=0 order by id desc"
elseif action="1" then
	sql=sql&"flag=1 order by id desc "
end if
end if
if keywords<>"" then sql=sql&" and postname like '%"&keywords&"%' order by id desc"
Set rs= Server.CreateObject("ADODB.Recordset") 
rs.open sql,conn,1,1
msg_per_page=20 '定义每页显示记录条数
%>
<!--#include file="../../inc/headpage.asp"-->
<table width="98%" border="0" cellspacing="0" cellpadding="0"  align=center class="tableBorder">
<tr> 
<th class="tableHeaderText" colspan=2 height=25> 会员供求管理</th>
</tr>
<tr>
<td   colspan=2> <span class="STYLE2"><FONT color="#666666">温馨提示： ①任何的删除操作都是不可逆的，执行删除时请慎重。 
 ②点击品牌信息查看或修改该条供求详细信息。 
③点击公司名查看或者修改用户"企业信息"。</font></span></td>
</tr>
<FORM name=searchForm action="postmanage.asp" method=post>
<tr>
<td width="19%" height=25 class="forumRowHighlight">
  <span class="STYLE2"><B>管理操作选项</B>  </span></td>
<td width="81%" class=forumRowHighlight STYLE2>关键字：<input name="keywords" type="text" value="<%=keyword%>">
&nbsp;类型：
<select name="action">
 <option value="0">待审品牌</option>
 <option value="1">已审品牌</option>
 
</select>
<input type="submit" value="立刻查找" id=submit name=submit> </td>
</tr>
</form><tr><td height="1" bgcolor="#CCCCCC" colspan="2"></td></tr>
 </table>
  <table width="98%" border="0" align="center" cellpadding="0" cellspacing="0" class="tableBorder">
	   <Form name="search" method="POST" action="postmanage.asp?action=<%=action%>&keywords=<%=keywords%>">
      <tr> 
                <td> 
  <TABLE width="100%" border="0" align="center" cellpadding="3" cellspacing="1" bordercolor="#111111" bordercolorlight="#D7EBFF" bordercolordark="#D7EBFF" style="border-collapse: collapse">
    <TBODY>
<%
if rs.eof then
response.Write"<br><br><div align='center'>暂无数据信息</div><br><br>"
else
%>
<TR height=25>
<TD width="87" height="20" class=bodytitle><font color="#CC3300"><b>品牌图片</b></font></TD> 
<TD width="206" height="20" align="center" class=bodytitle><font color="#CC3300"><b>项目标题</b></font></TD>
<TD width="115" height="20" align="center" class=bodytitle><font color="#CC3300"><b>品牌名称</b></font></TD>
<TD width="132" class=bodytitle align=center><font color="#CC3300"><b>所在地区</b></font></div></TD>
      <TD width="155" align="center" class=bodytitle><font color="#CC3300"><b>发布公司</b></font></TD>
      <TD width="145" align="center" class=bodytitle><font color="#CC3300"><b>发布时间</b></font></TD>
      <TD width="152" class=bodytitle align="center"><font color="#CC3300"><b>操作</b></font></TD>
<TD width="57" align="center" class=bodytitle><input type='submit' value='删除' onClick="{if(confirm('您确定执行的操作吗?')){this.document.even.submit();return true;}return false;}"></TD>
</TR>
<%
do while not rs.eof and rowcount > 0
drawalt=rs("logo")
url=trim(rs("username"))%>
<TR height="50"> 
<td width="87" height="50" class=forumRow style="word-break:break-all" align="center">
<%if drawalt="http://" then%>
无图
<%else%>
<a href="edit.asp?id=<%=rs("id")%>"><img src="../../vipcom/<%=url%>/<%=drawalt%>" width="80" height="50" border="0"></a>
<%end if%></td>
<td width="206" align="center" class=forumRow style="word-break:break-all"> &nbsp;<%=rs("project")%></td>
<td width="115" align="center" class=forumRow style="word-break:break-all"><a href="edit.asp?id=<%=rs("id")%>"><%=rs("postname")%></a></td>
<td width="132" class=forumRow align=center><%=rs("country")%>
<%if rs("province")<>"" then %>
-<%=rs("province")%>-<%=rs("city")%>

<% end if %></td>
<td width="155" align="center" class=forumRow><%=rs("company")%></td>
<td width="145" align="center" class=forumRow><%=rs("datetime")%></td>
<td width="152" class=forumRow align="center">
<% if rs("Flag")=1 then %>
     <font color="#FF0000"><a href="shenhe.asp?id=<%=rs("id")%>&m=3">已审核</a></font>
<%else%>
     <p align="center"> <a href="shenhe.asp?id=<%=rs("id")%>&m=0"> 
     <font color="#008000">未审核</font></a>
<%end if%>/
<%if rs("hot")=0 then %>
<a href="shenhe.asp?id=<%=rs("id")%>&m=1">未推荐
<%else%>
<a href="shenhe.asp?id=<%=rs("id")%>&m=2"> <font color="#FF0000">已推荐</font>
<%end if%>
</td>
<td width="57" align="center" class=forumRow><input type='checkbox' name='selAnnounce' value='<%=cstr(rs("id"))%>'></td>
</tr>
<%
icolor=icolor+1
if icolor>1 then icolor=0
rowcount=rowcount-1
rs.movenext
loop
end if
%>
</TABLE>
</td>
    </tr>
			  <tr><td align="right" class=forumRow><input type=button value=" 全部选定 " onClick="this.value=check(this.form)"></div></td></tr>
              <tr>
                <td class=forumrowHighLight align="center"><b><%=listPages("postmanage.asp?action=0")%></b></td>
              </tr></form>
</table>
<%
sub deleteannounce(id)
dim rs,sql

sql="delete from [Websen_post] where id in("&cstr(id)&")"

Conn.Execute(sql)  


if err.Number<>0 then
err.clear
response.write "删 除 失 败 !<br>"
end if
End sub
%>
<!--#include file="../copy.asp"-->