<!--#include file="conn.asp"-->
<!--#include file="ad_chk.asp"-->
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<link href=inc/css.css rel=STYLESHEET type=text/css>
<body topmargin="5" leftmargin="5" rightmargin="5" bottommargin="5">
<%
if Request.Cookies("WrzcNet")("admin_class")<>0 and Request.Cookies("WrzcNet")("admin_class")<>1 then
response.write "你没有这个权限!"
response.end
end if
%>
<%
pinpai_id=request("pinpai_id")
if request("action")="add" then
	set rs=server.CreateObject("adodb.recordset")
	rs.Open "select * from WrzcNet_pinpai",conn,1,3
	rs.AddNew
	rs("pinpai_name")=request("pinpai_name")
	rs("pinpai_logo")=request("pinpai_logo")
	rs("pinpai_content")=request("pinpai_content")
	rs("pinpai_xu")=request("pinpai_xu")
	if seo_pinpai1=1 then rs("pinpai_title")=request("pinpai_title")
	if seo_pinpai3=1 then rs("pinpai_keyword")=request("pinpai_keyword")
	if seo_pinpai5=1 then rs("pinpai_d")=request("pinpai_d")
	rs.Update
	rs.Close
	set rs=nothing
	call addok(addt,"ad_pinpaiadd.asp","ad_pinpai.asp")
end if

if request("action")="edit" then
	set rs=server.CreateObject("adodb.recordset")
	rs.open "select * from WrzcNet_pinpai where pinpai_id="&pinpai_id&"",conn,1,3
	rs("pinpai_name")=request("pinpai_name")
	rs("pinpai_logo")=request("pinpai_logo")
	rs("pinpai_content")=request("pinpai_content")
	rs("pinpai_xu")=request("pinpai_xu")
	if seo_pinpai1=1 then rs("pinpai_title")=request("pinpai_title")
	if seo_pinpai3=1 then rs("pinpai_keyword")=request("pinpai_keyword")
	if seo_pinpai5=1 then rs("pinpai_d")=request("pinpai_d")
	rs.update
	rs.close
	set rs=nothing
	call editok(editt,"ad_pinpaiedit.asp?pinpai_id="&pinpai_id,"ad_pinpai.asp")
end if

if request("action")="del" then
conn.execute "delete from WrzcNet_pinpai where pinpai_id="&pinpai_id
call deleok(delet,"ad_pinpai.asp")
end if

%>

<table border="0" cellpadding="5" class=st cellspacing="0">
<tr><td class="sa"><b>品牌管理</b></td>
	<td align="center" class="sa">排序</td>
	<td align="center" class="sa">查看</td>
	<td align="center" class="sa"><b>操作</b></td></tr>
<%set rs=server.CreateObject("adodb.recordset")
rs.open "select * from WrzcNet_pinpai order by pinpai_xu DESC,pinpai_id DESC",conn,1,1
xx=0
do while not rs.eof
xx=xx+1%>
<tr>
<td class="s<%=xx mod 2%>" bgcolor="#FFFFFF" valign="top"><a href=ad_pinpaiedit.asp?pinpai_id=<%=rs("pinpai_id")%>><%=rs("pinpai_name")%></a></td>
<td class="s<%=xx mod 2%>" align="center" bgcolor="#FFFFFF" valign="top"><%=rs("pinpai_xu")%></td>
<td class="s<%=xx mod 2%>" align="center" bgcolor="#FFFFFF" valign="top"><a target=_blank href="../pinpai.asp?pinpai_id=<%=rs("pinpai_id")%>">查看</a></td>
<td class="s<%=xx mod 2%>" align="center" bgcolor="#FFFFFF" valign="top">&nbsp;&nbsp;
<a href=ad_pinpaiedit.asp?pinpai_id=<%=rs("pinpai_id")%>>修改</a>&nbsp;&nbsp;&nbsp;
<a href=ad_pinpai.asp?action=del&pinpai_id=<%=rs("pinpai_id")%> onClick="return confirm('您确定进行删除操作吗？')">删除</a>&nbsp;&nbsp;</td>
</tr>
<%
rs.movenext
loop
rs.close
set rs=nothing%></table>
<!--#include file="ad_bottom.asp"-->