hi, mein login.asp skript sieht so aus:
<html>
<head>
<title>Login</title>
</head>
<body bgcolor=#ffffff>
<form method="post" action="login.asp">
<table border=0>
<tr><td bgcolor=#CCCCCC>Username</td><td><input type=text size=40 maxlenght=40 name=Username></td></tr>
<tr><td bgcolor=#CCCCCC>Passwort</td><td><input type=password size=40 maxlenght=40 name=Password></td></tr>
<tr><td></td><td></td></tr>
<tr><td><input type=submit value="login" name=login></td></tr></table></form>
<% @ Language=VBScript %>
<%
bValidationFailed = False
If Request.ServerVariables("CONTENT_LENGTH") > 0 Then
strUsername = Trim(Request.Form("txtUsername"))
strPassword = Trim(Request.Form("txtPassword"))
Set conn = Server.CreateObject("ADODB.Connection")
Set rs = Server.CreateObject("ADODB.Recordset")
strPath = Server.MapPath("login.mdb")
strConnection = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & strPath
conn.Open strConnection
rs.Open "select * from users where Username='" & strUsername & "' AND Password='" & strPassword & "'", conn
If not rs.EOF and not rs.BOF then
' beliebige Daten aus der Tabelle auslesen...
Session("AccessGranted") = True
rs.Close
conn.Close
Response.Redirect "feedback.htm"
Response.End
End if
Response.AppendToLog " Logon failed: " & strUsername & " " & strPassword
bValidationFailed = True
End If
%>
</body>
</html>
Ich habe alles auf einer Seite.
Muß ich das Formular separat gestallten und dann den tag-action auf login.asp verweisen?
grüße, andi