论文首页哲学论文经济论文法学论文教育论文文学论文历史论文理学论文工学论文医学论文管理论文艺术论文 |
<%
dim id
dim strSQL
id = Request.QueryString("id")
strSQL = "DELETE FROM st_info WHERE ID =" & id & ""
'Response.Write strSQL
'Response.End
conn.execute (strSQL)
%>
<script language = java script>
<!--
alert("删除成功!");
window.location = "info-manager.asp"
//-->
</script>
修改学生信息的功能是通过文件updataxx.asp和updataxx1.asp来实现的.它的原理是通过连接数据库,找到该记录,然后通过更新记录中的数据就可以完成信息个修改功能。代码如下:
把修改后的数据保存到数据库updataxx1.asp
<!-- #include file = "data.asp" -->
<!--#include file="user.asp"-->
<%
dim strSQL, cmdObj, rsObj
Set cmdObj = Server.CreateObject("ADODB.Command")
Set rsObj = Server.CreateObject("ADODB.RecordSet")
cmdObj.CommandText = "SELECT top 1 * FROM st_info ORDER by ID desc"
cmdObj.CommandType = 1
Set cmdObj.ActiveConnection = conn
rsObj.Open cmdObj, , 2,3
rsObj("user_number") = Request.Form("user_number")
rsObj("user_name") = Request.Form("user_name")
rsObj("user_zkzh") = Request.Form("user_zkzh")
rsObj("user_sfzh") = Request.Form("user_sfzh")
rsObj("user_sex") = Request.Form("user_sex")
rsObj("user_time") = Request.Form("user_time")
本文来自中国科教评价网
<!--#include file="data.asp"-->
<!--#include file="user.asp"-->
<%
set rsobj=server.createobject("adodb.recordset")
sql="select * from cj order by id desc"
rsobj.open sql,conn,1,1
%>
<html>
<head>
<meta http-equiv="Content-Language" content="zh-cn">
<meta http-