📄 smallclass_modi.asp
字号:
<!--#include file="chk.asp"-->
<!--#include file="db_conn.asp"-->
<!--#include file="../my_lib/my_request.asp"-->
<%
id=my_request("id",1)
iid=my_request("iid",1)
smallclass=my_request("name",0)
action=my_request("action",0)
if action="save" then
call save()
response.write "<script>window.opener.document.location.reload();</script>"
response.write "<script>window.close();</script>"
else
%>
<html>
<head>
<meta http-equiv="Content-Language" content="zh-cn">
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<LINK href="style.css" rel=stylesheet type=text/css>
<script language="javascript">
function checkdata()
{
if (document.form1.iid.value=="")
{
alert("对不起,请先选择大类别!")
document.form1.iid.focus()
return false
}
if (document.form1.smallclass.value=="")
{
alert("对不起,类别不能为空!")
document.form1.smallclass.focus()
return false
}
}
</script>
<title>小类别修改</title>
</head>
<body>
<form action="smallclass_modi.asp" method="post" name=form1 onsubmit="return checkdata();">
<table border="0" width="100%" id="table1" cellspacing="0" style="border-collapse: collapse" cellpadding="0">
<tr>
<td background="image/admintoptdbg.gif">
<p align="left">
<img border="0" src="image/title_arrow.bmp" width="17" height="27" align="absmiddle"><font color="#808080"><b>小类别修改</b></font></td>
</tr>
</table>
<table width="100%" id="table1" style="border:1px solid #C0C0C0; padding-left:4px; padding-right:4px; padding-top:1px; padding-bottom:1px" cellpadding="4" bgcolor="#F6F6F6">
<tr>
<td>请选择大类:<select size="1" name="iid">
<option value="">请选择...</option>
<%sql="select id,txt_big_class from big_class order by addtime"
set rs=conn.execute (sql)
do while not rs.eof
%>
<option value="<%=rs("id")%>" <%if cint(rs("id"))=cint(iid) then%> selected <%end if%>><%=rs("txt_big_class")%></option>
<%rs.movenext
loop
rs.close
set rs=nothing
%>
</select><br>
名称:<input type="text" name="smallclass" size="23" value="<%=smallclass%>" maxlength="20">
<input type="hidden" name="action" value="save">
<input type="hidden" name="id" value="<%=id%>">
</td>
</tr>
<tr>
<td>
<p align="center"><input type="submit" value="修 改" name="B1">
<input type="button" value="关闭窗口" name="B2" onclick="window.close()"></td>
</tr>
</table>
</form>
<div align="center">
<table border="0" width="100%" id="table3" cellspacing="0" cellpadding="0">
<tr>
<td align=right><input TYPE="button" VALUE="刷新本页" ONCLICK="location.reload()"> </td>
</tr>
</table>
</div>
</body>
</html>
<%end if
sub save()
smallclass=my_request("smallclass",0)
id=my_request("id",1)
iid=my_request("iid",1)
sql="update small_class set iid="&iid&",txt_small_class='"&smallclass&"' where id="&id
conn.execute (sql)
conn.close
set conn=nothing
end sub
%>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -