asp教程添加数据库教程记录
<form name="form" method="post" action="">
<label>
<input name="uid" type="text" id="uid">
</label>
用户名
<p>
<label>
<input name="pwd" type="text" id="pwd">
</label>
密码
<input type="hidden" name="action" value="add">
</p>
<p>
<label>
<input type="submit" name="Submit" value="增加">
</label>
</p>
</form>
<%
asp添加数据库记录
Dpath ="wwwliannet/dbaseMateyDBWeb_^%$#@mdb"
Set Conn=ServerCreateObject("Adodbconnection")
if requestQueryString("action")="add" then
Set Rs =ServerCreateObject("AdodbRecordset")
Connconnectionstring="Provider=MicrosoftJetoledb;Data source="&ServerMapPath(Dpath)
Connopen
Dim sql
sql ="select * from test "
rsopen sqlconn
rsaddnew
rs("uid")=request("uid")
rs("pwd")=request("pwd")
rsupdate
responseWrite("数据保存成功")
end if
%>