/*******************************/
/**** BCR PASSWORD BOX ****/
/*** FREEWARE JS SCRIPT ***/
/** Fell free to edit **/
/* But Please send ideas to me */
/** at benrob@talk21.com **/
/*** IF USED ON YOUR WEBSITE ***/
/**** SEND ME AN E-MAIL AND ****/
/***** GIVE ME THE CREDIT *****/
/****** E-mail me at ******/
/***** benrob@talk21.com *****/
/*******************************/
/*
To add/change users & Passwords just change the users array
and passwords were it tells you.
You can have as many/little as you like
When you add a new user be sure to add a Pass word
so a new user would look like
" users[7] = 'username'; pass[7] = 'password' "
(without "s)
REMEMBER: Usernames & Passwords are case sensative so 'pass'
is differnt to 'Pass' & 'PaSs'
*/
// -------- Set Vars -----------
var users = new Array()
var pass = new Array()
users[0] = 'Admin'; pass[0] = 'Pass' //Leave this Username for Webmaster (you) but change password
//Add/change user names here & Add/chage passwords here
users[1] = 'User1'; pass[1] = 'Pass1' //User1 name & password
users[2] = 'User2'; pass[2] = 'Pass2' //User2
users[3] = 'User3'; pass[3] = 'Pass3' //User3
users[4] = 'User4'; pass[4] = 'Pass4' //ect
users[5] = 'User5'; pass[5] = 'Pass5'
users[6] = 'User6'; pass[6] = 'Pass6'
var wrighturl = 'pass.htm' //Page you want the user to go to if Password is wright
var wrongurl = 'wrong.htm' // " " " " " " " " " " " " wrong
//-----------------------------------------
//----------- Leave this alone ------------
function isPass(){
var dn = document.nameenter
userN = dn.usern.value
passV = dn.pass.value
if (userN.length < 1){ alert('Enter Username'); return false }
if (passV.length < 1){ alert('Enter Password'); return false }
for (var i = 0; i < users.length ; i++){
if (users[i] == userN && pass[i] == passV){ location.href = wrighturl; return false}
if (users[i] == userN && pass[i] != passV){ location.href = wrongurl; return false}
}
location.href = wrongurl
}
function list(){
userO=window.open('about:blank','winID','height=400,width=200,top=100,left=100,location=no,menubar=no,resizable=yes,scrollbars=yes,status=no,toolbar=no')
userO.document.write(' List Of Users
\n')
for (var u = 0; u < users.length; u++){
userO.document.write(' » ' + users[u] + "
\n")
}
userO.document.write(' Close ')
}
//------------------------------------------
//------------------------------------------
// DISCLAIMER
// USE SCRIPT AT OWN RISK