ASP Tutorial User Registration Instance Program
Create an Access database tutorial Db1.mdb, where you create a datasheet user, the fields are: U_uid (Automatic), U_user (user name: Text type), U_pass (password: text type)
Set up the form data sent from the receiving register.asp, and insert the successful display page of the registration in Datasheet User:
<%
' Method of string connection to database
Set Conn=server.createobject ("Adodb.connection")
Conn.Open "Driver=driver do Microsoft Access (*.mdb); uid=admin;pwd=;d bq=" &server.mappath ("Regdb1.mdb")
%> save data to database method
<%@ language=vbscript%>
<!--#include file= "con1.asp"-->
&L T;meta http-equiv= "Content-type" content= "text/html; charset=gb2312 "/>
<title> Registration Successful </title><br>
<body>
<%
Create Recordset object method
Set Rst=server.createobject ("Adodb.recordset")
Set Rst1=conn.execute ("INSERT INTO User" ( U_user,u_pass) VALUES (' "&request.form (" U_user ") &", "&request.form (" U_pass ") &") "
%>
<table width= border= "0" align= "center" >
<tr>
<td align= "center" ></td>
</tr>
</table>
</body >