?? smallclassadd.asp
字號:
<!--#INCLUDE FILE="Conn.asp" -->
<%
IF Session("KEY")<>"super"THEN
response.redirect "index_face.asp"
response.end
END IF
dim typename
dim howmany
sBigClassName=request("bigclassName")
typename=request("type")
howmany=request("howmany")
If typename="" Then
response.write "不能為空!"
response.end
end if
set rs=server.createobject("adodb.recordset")
sql="select * from smallclass"
rs.open sql,conn,3,3
do while not rs.eof
if rs("SmallClassName")=typename then
response.write "已經(jīng)存在這個SmallClassName名稱!請<a href=javascript:history.go(-1)>返回重新填寫</a>!"
response.end
end if
rs.movenext
loop
rs.close
set rs=nothing
Set rs = Server.CreateObject("ADODB.Recordset")
sql="select * from smallclass"
rs.open sql,conn,1,3
rs.addnew
rs("SmallClassName")=typename
rs("SmallClassID")=howmany+1
rs("BigClassName")=sBigClassName
rs.update
rs.close
set rs=nothing
conn.close
set conn=nothing
response.redirect "SmallClass.asp"
%>
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -