%
Username="user"
Password="pass"
' if any of the variables do not match, create error message
if Request.Form("login") <> Username or Request.Form("password") <> Password then
MsgErr = "
Authorization Failed.
"
Response.Write MsgErr
' if correct, set the session variable and proceed
Else
Session("someStringValue") = true
' redirect
If Len(Request("requester")) > 0 Then
Response.Redirect (Request("requester"))
Else
Response.Redirect "protected.asp"
End if
End if
%>
Results -- Login