View Single Post
Old 11-17-2004, 12:30 PM   #1 (permalink)
buchannon
Registered User
 
buchannon's Avatar
 
Join Date: Nov 2004
Posts: 43
buchannon is on a distinguished road
ASP login with access

I'm trying to create a very simple logon using a number kids receieve at our school called the "bearnumber"

I found a sample ASP code to work with access and got everything working. I just had a few questions. If someone doesn't mind answering or pointing me in the direction of a good tutorial, that would be uber.

In this part of the script, what is going on?
Quote:
strSQL = "SELECT * FROM tblLoginInfo " _
& "WHERE bearnumber='" & Replace(Request.Form("bearnumber"), "'", "''") & "';"

Set cnnLogin = Server.CreateObject("ADODB.Connection")
cnnLogin.Open("DRIVER={Microsoft Access Driver (*.mdb)};" _
& "DBQ=" & Server.MapPath("login.mdb"))

Set rstLogin = cnnLogin.Execute(strSQL)

If Not rstLogin.EOF Then
Also, in this line, what do all the ''',''' & ";" mean?
Quote:
& "WHERE bearnumber='" & Replace(Request.Form("bearnumber"), "'", "''") & "';"
buchannon is offline   Reply With Quote