<%dbdns="../../"%>
<!--#include file="../../inc/conn.asp"-->
<!--#include file="../cook.asp"-->
<%if fla3<>1 then
response.write "<script>alert('操作权限出错，您没有权限操作些功能');history.go(-1);</Script>"
Response.End 
end if%>
<%
if request("action")="del" then
conn.execute("delete from dlxf_scasort where dlxf_id=" & request("id"))


set rs = Server.CreateObject("ADODB.Recordset")
sql="select *  from dlxf_sca where dlxf_scasort=" & request("id")
rs.open sql,conn,1,1
do while not rs.eof
conn.execute("delete from dlxf_leaveword where dlxf_book_sort=3 and dlxf_book_table="&rs("dlxf_id")&"")
rs.movenext
loop
rs.close
set rs=nothing

conn.execute("delete from dlxf_sca where dlxf_scasort=" & request("id"))
end if%>
<%=citycss%>
<body style="margin:10">
<table width="100%" height="0" border="1" align="center" cellpadding="0" cellspacing="0" bordercolorlight="#6C90D1" bordercolordark="#FFFFFF">
  <form name="form1" method="post" action="sca_sort_save.asp?action=add">
    <tr align="center" bgcolor="#D6DFF7"> 
      <td width="29%" height="25">添加分类</td>
      <td width="37%"><input type="text" name="scasort"></td>
      <td width="34%"><input type="submit" name="Submit" value="添加" class=input1></td>
    </tr>
  </form>
</table>

<!--#######################################################################-->
<table width="100%" height="0" border="1" align="center" cellpadding="0" cellspacing="0" bordercolorlight="#6C90D1" bordercolordark="#FFFFFF">
<tr align=center>
<%sql="select * from dlxf_scasort order by dlxf_date desc"
set rs=Server.CreateObject("ADODB.Recordset")                                                    
rs.open sql,conn,1,1 
if (rs.eof and rs.bof) then
	response.write "<td height=20 colspan=3>暂无内容</td>"
else                                                 
n=0
do while not rs.eof
n=n+1%>
<td width="20%" height="25"><a href=sca_sort.asp?id=<%=rs("dlxf_id")%>&scasort=<%=rs("dlxf_scasort")%>><%=rs("dlxf_scasort")%></a> <a href=sca_sort_save.asp?id=<%=rs("dlxf_id")%>&action=aa><font color=#6C90D1>排序</font></a></td>
<%if n mod 5=0 then response.write("</tr><tr align=center>")
rs.movenext
loop
end if
rs.close
set rs=nothing%>
</tr>
</table>
<!--#######################################################################-->
<%if request("scasort")<>"" then%>
<br>
<table width="100%" height="0" border="1" align="center" cellpadding="0" cellspacing="0" bordercolorlight="#6C90D1" bordercolordark="#FFFFFF">
  <form name="form1" method="post" action="sca_sort_save.asp?action=edit&id=<%=request("id")%>">
    <tr align="center" bgcolor="#D6DFF7"> 
      <td width="29%" height="25">修改分类</td>
      <td width="37%"><input type="text" name="scasort" value="<%=request("scasort")%>"></td>
      <td width="34%"><input type="submit" name="Submit" value="修改" class=input1>　　<a href=sca_sort.asp?id=<%=request("id")%>&action=del>删除</a></td>
    </tr>
  </form>
</table>
<%end if%>