Ich habe ein Anmelde Forumular erstellt und eine DB funktioniert auch alles,
nur funktioniert das Login Script nicht.
Wo k�nnte der Fehler liegen ??
Hier der Quelltext:
<%
Option Explicit
Dim sql,rsUser,username,password,page,sqlflag
'Grab the submitted variables (page is the page they've come from, set by
the hidden variable at the login box)
Nickname = Request.Form("username")
Passwortd = Request.Form("password")
page = Request.Form("page")
if page = "" then
page = "index.asp"
end if
'Open connection
%>
<!--#include file="conn.asp"-->
<%
'Get a recordset corresponding to the submitted username and password
sql = "SELECT nickname FROM user WHERE nickname = '" & nickname & "' AND
passwort = '" & passwort & "'"
Set rsUser = Server.CreateObject("ADODB.Recordset")
rsUser.Open sql, conn, 3, 3
'If there was a valid recordset there, then send them back to the page they
came from, with the username cookie set
If (not rsUser.BOF) and (not rsUser.EOF) and sqlflag <> True then
Response.Cookies("nickname") = rsUser("nickname")
end if
rsUser.close
set rsUser = nothing
conn.close
set conn = nothing
Response.Redirect(page)
end if
'Otherwise, display an invalid entry screen
rsUser.close
set rsUser = nothing
conn.close
set conn = nothing%>
Also ich hoffe mir kann jeamand von euch helfen
Gute Nacht
cu Erik
| Oft Gefragtes: http://www.aspgerman.com/aspgerman/faq/
| [aspdebeginners] als [email protected] subscribed
| http://www.aspgerman.com/archiv/aspdebeginners/ = Listenarchiv
| Sie knnen sich unter folgender URL an- und abmelden:
| http://www.aspgerman.com/aspgerman/listen/anmelden/aspdebeginners.asp