View Single Post
  #1 (permalink)  
Old Aug 3rd, 2007, 01:26
sehrlund sehrlund is offline
New Member
Join Date: Aug 2007
Location: Toronto
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Cool How to change login/password script for multiple users

Help....I am a Javascript newbie! I am trying to create a js file with login IDs and passwords for multiple users. The code I have is for one user.
How do I change this code to accomodate multiple users:
Code: Select all
function authUser(form) { 
if (form.Username.value=="member1") { 
if (form.Password.value=="testing") { 
location="Welcome.html" 
} else { 
location="UnAuthorized.html"
} 
} else { 
location="UnAuthorized.html"
} 
}

I have tried a whole lot of things but nothing recognizes more than one user. Any help would be greatly appreciated.

Last edited by karinne; Aug 3rd, 2007 at 12:02. Reason: Please use [ code ]...[ /code ] tags when displaying code.
Reply With Quote