% @Language=VBScript %>
<% ' *** update_login.asp - Updated: 12/27/2007 - dlb ***
Option Explicit
Dim user, pw, intNoUsers, intUserNumber, i
Dim arrUser, arrPassword, arrName
Dim fs, fo, strRoot
' ****** Set number of users, usernames, passwords, and names here ******
intNoUsers = 2
arrUser = Array("null","bob","beaty")
arrPassword = Array("null","identity0","dlb49")
arrName = Array("null","Bob Feig","Don Beaty")
' ****** End Set user names and passwords ******
'srtRoot = Request.ServerVariables("APPL_PHYSICAL_PATH")
If request.ServerVariables("CONTENT_LENGTH") <> 0 Then
session("feigUser") = Trim(Request.Form("user"))
session("feigPassword") = Trim(Request.Form("password"))
End If
user = session("feigUser")
pw = session("feigPassword")
%>
Feig Agency - Office Use Only
Feig Agency
ADMINISTRATOR'S PAGE
(For Office Use Only)
<%
intUserNumber = 0
For i = 1 to intNoUsers
If user = arrUser(i) and pw = arrPassword(i) Then intUserNumber = i
Next
If user = "" and pw = "" Then
' ****** Log In Section ******
Session("Login") = "True"
%>
<%
ElseIf intUserNumber > 0 Then
' *** Hello User - Continue ***
If Session("Login") Then
Set fs = Server.CreateObject("Scripting.FileSystemObject")
Set fo = fs.OpenTextFile(Server.MapPath("update_log.dat"),8,True)
fo.WriteLine(user & ": " & Now)
fo.Close
Set fo = nothing
Set fs = nothing
End If
Session("Login") = "False"
%>