Hi, This 'simple' script I've made is supposed to check the parameters from the url (random number) check against those in the database and then activate the users account but it won't work and i'm not sure why. Any ideas,Its been a long day.... Thanks
<%
DIM objConn
Set objConn = Server.CreateObject("ADODB.Connection")
objConn.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & Server.MapPath ("database/fiat127.mdb") & ";"
objConn.Open
'Get the parameters from the email URL
user_mail = Request.QueryString("email")
auth_code = Request.QueryString("activate")
auth_int = CLng(auth_code)
%>
<%
check = "SELECT * FROM users WHERE random_auth ="&auth_int
objConn.Execute check
If objConn.check.EOF Then (**THE ERROR IS HERE, **)
authenticate = "UPDATE users SET auth_flag=True WHERE random_auth="&auth_int
objConn.Execute authenticate
%>
<%
Response.Redirect("confirmed.asp")
Else
Response.Redirect("confirmed_error.asp")
End If
%>
<%
DIM objConn
Set objConn = Server.CreateObject("ADODB.Connection")
objConn.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & Server.MapPath ("database/fiat127.mdb") & ";"
objConn.Open
'Get the parameters from the email URL
user_mail = Request.QueryString("email")
auth_code = Request.QueryString("activate")
auth_int = CLng(auth_code)
%>
<%
check = "SELECT * FROM users WHERE random_auth ="&auth_int
objConn.Execute check
If objConn.check.EOF Then (**THE ERROR IS HERE, **)
authenticate = "UPDATE users SET auth_flag=True WHERE random_auth="&auth_int
objConn.Execute authenticate
%>
<%
Response.Redirect("confirmed.asp")
Else
Response.Redirect("confirmed_error.asp")
End If
%>