Det är fel i filen registeruser.asp jaha? vad är det för fel då, vad får du för felmeddelande?Jag undrar om det är någon som kan hjälpa mig med ett ASPscript.
<%@ Language=VBScript %>
<% Option Explicit %>
<!--#include file="adovbs.inc"-->
<HTML>
<BODY>
<%
Dim objRS, bolAlreadyExists, objConn, valid
dim Susername, Spassword, Semail, Sfirstname, Slastname
Susername=Replace(Request.form("username"), "'", "''")
Susername=Trim(Replace((Susername),"""",""""""))
Susername=Replace((Susername), "<", "t")
Susername=Replace((Susername), ">", "t")
Spassword=Replace(Request.form("password"), "'", "''")
Spassword=Trim(Replace((Spassword),"""",""""""))
Spassword=Replace((Spassword), "<", "t")
Spassword=Replace((Spassword), ">", "t")
Semail=Replace(Request.form("email"), "'", "''")
Semail=Trim(Replace((Semail),"""",""""""))
Semail=Replace((Semail), "<", "t")
Semail=Replace((Semail), ">", "t")
Sfirstname=Replace(Request.form("firstname"), "'", "''")
Sfirstname=Trim(Replace((Sfirstname),"""",""""""))
Sfirstname=Replace((Sfirstname), "<", "t")
Sfirstname=Replace((Sfirstname), ">", "t")
Slastname=Replace(Request.form("lastname"), "'", "''")
Slastname=Trim(Replace((Slastname),"""",""""""))
Slastname=Replace((Slastname), "<", "t")
Slastname=Replace((Slastname), ">", "t")
valid = Session("verify")
if valid =155 then
If ((Susername = "") OR (Spassword = "") _
OR (Semail = "") OR (Sfirstname = "") _
OR (Slastname = "")) Then
Response.Write ""
Response.Write "You must enter values for all the fields."
Response.Write ""
Else
BolAlreadyExists = False
Set objRS = Server.CreateObject("ADODB.Recordset")
Set objConn = Server.CreateObject("ADODB.Connection")
'Create a DSN-less database connection (M&A p. 512)
Set objConn = Server.CreateObject("ADODB.Connection")
objConn.ConnectionString="DRIVER={Microsoft Access Driver (*.mdb)};" & _
"DBQ=c:\inetpub\wwwroot\file\empirical"
objConn.Open
objRS.Open "collected", objConn, , 3, adCmdTable
Do While Not (objRS.EOF OR bolAlreadyExists)
If (StrComp(objRS("user_name"), Susername, _
vbTextCompare) = 0) Then
Response.Write ""
Response.Write "Username already exists."
Response.Write ""
bolAlreadyExists = True
End If
If (StrComp(objRS("email"), (Semail), _
vbTextCompare) = 0) Then
Response.Write ""
Response.Write "Email address already found in table."
Response.Write ""
bolAlreadyExists = True
End If
objRS.MoveNext
Loop
If Not bolAlreadyExists Then
objRS.AddNew
objRS("FirstName") = Sfirstname
objRS("LastName") = Slastname
objRS("email") = Semail
objRS("user_name") = Susername
objRS("password") = Spassword
objRS("date_created") = now
objRS.Update
Response.Write "Thank you for registering."
Response.Write "Login " & "" & "Here" &""
End If
objRS.Close
Set objRS = Nothing
End If
End if
objConn.Close
Set objConn = Nothing
%>
</BODY>
</HTML>Sv: Jag undrar om det är någon som kan hjälpa mig med ett ASPscri