<!--#include file=CONN.ASP-->
<!--#include file=cookies.asp-->
<title>修改分类</title>
<%
dim rs,sql,sheng,shi,paixu,classid,leibie
classid=trim(request("classid"))
sheng=request("sheng")
shi=trim(request("shi"))
paixu=trim(request("paixu"))
if sheng="" then
response.write "<li>错误，类别为空！"
call cl()
response.end
end if
if shi="" then
response.write "<li>错误，类别为空！"
call cl()
response.end
end if
if paixu="" then
response.write "<li>错误，类别为空！"
call cl()
response.end
end if
set rs = Server.CreateObject("ADODB.RecordSet")
sql="select * from [FOX_shi] where id="&cstr(classid)
rs.open sql,conn,1,3
leibie=trim(rs("shi"))
if shi=leibie then
rs("paixu")=paixu
rs.update
response.write "排序修改成功！"
call cl()
response.end
end if

if rs.eof then
response.write "参数错误！"
call cl()
else
rs("sheng")=sheng
rs("shi")=shi
rs("paixu")=paixu
rs.update
response.write "修改成功！！"
call cl()
end if
rs.close
set rs=nothing
closedb
%>
<%sub cl()
response.write "<meta http-equiv=refresh content=""1;URL=diqu.asp"">"
end sub%></body></html>