<%@language=vbscript%> <% Option Explicit Response.Expires = -1000 %> <% Dim strCheckLogin, rsCheckLogin Set rsCheckLogin = Server.CreateObject("ADODB.Recordset") strCheckLogin = "SELECT * FROM tblLogin WHERE UserName = '" & Request("UserName") & "' AND UserPass = '" & Request("UserPass") & "'" 'Response.write(strCheckLogin) rsCheckLogin.Open strCheckLogin, oConn, 3 If rsCheckLogin.RecordCount >= 1 Then Session("LoginID") = Request("rsCheckLogin.UserID") Response.Redirect("list.asp") Else Response.Redirect("default.asp?MSG=INVALID") End If %>