?? admin_editclasschk.asp
字號:
<%@LANGUAGE="VBSCRIPT" CODEPAGE="936"%>
<!--#include file="xuanke.asp" -->
<!--#include file="include/is_admin.asp" -->
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>班級管理</title>
<style type="text/css">
<!--
@import url("style.css");
-->
</style>
</head>
<body bgcolor="#FFFFCC">
<div align="center">
<table width="706" height="281" border="0" class="table_big">
<tr>
<td valign="top"><div align="center">
<!--#include file="include/admin_head.asp" -->
<%
dim err(3)
dim cno,cname,ctime,credit,c_tname,haveerr,rs_edit,rs_edit_pre,c_limte,remarks,sql
'接收表單數據-------------
cno=request.Form("cno")
csno=request("csno")
classdesc=request.Form("classdesc")
classlimit=request.Form("classlimit")
cday=request.Form("cday")
cctime=request.Form("cctime")
'檢查數據--------------------
'根據haveerr值進行不同操作顯示不同結果---------------------
If haveerr = 0 Then
'打開課程數據庫--------------------
set rs_edit=server.CreateObject("adodb.recordset")
sql = "select * from class where id=" & csno
rs_edit.open sql,xuanke_conn,3,2
rs_edit("classdesc")=classdesc
rs_edit("cday")=cday
rs_edit("classlimit")=classlimit
rs_edit("cctime")=cctime
rs_edit.update
%>
<br>
<table width="421" border="0" class="table_small">
<tr>
<td> </td>
</tr>
<tr>
<td class="text_title"><div align="left">班級修改成功</div></td>
</tr>
<%Response.Redirect "admin_class.asp?cno="&cno%>
<tr>
<td class="table_title"> </td>
</tr>
<tr>
<td> </td>
</tr>
</table>
<% Else %>
<br>
<table width="418" border="0" class="table_small">
<tr>
<td width="10"> </td>
</tr>
<tr>
<td class="text_title"><div align="left">發現以下錯誤:</div></td>
</tr>
<tr>
<td class="table_title"> </td>
</tr>
<tr>
<td class="text_error">
<div align="left">
<%
for i=1 to 3
if err(i) <> "" then response.Write("●" & err(i) & "<br>")
next
%>
</div></td>
</tr>
<tr>
<td> </td>
</tr>
</table>
<% End If %>
<br>
</div></td>
</tr>
</table>
</div>
</body>
</html>
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -