Stroup
06-06-2002, 10:27 AM
}:-)
I am new to JavaScripting and this is my very first script. Well you see I play this online game, and I have a site that I would like to have a members area in. This passwordCode i have been having troubles with. Can someone point me in the right direction?
<HTML>
<SCRIPT LANGUAGE="JScript">
<BODY onload=getpassword()>
function getpassword()
var password = prompt
("Im gonna need to see some ID"), ("xxxxxxxx")
if (password == "assassin") {
document.writln("<BODY><H1>Good your one of us!</H1>
Sorry about that but the boss says we need it.
</BODY>")
else
document.writeln("<BODY><H1>Incorrect</H1>You have attempted to access
our site without registered password. Please leave or
hit your <B>back</B> button and try again. </BODY>")
</SCRIPT>
</HEAD>
</BODY>
</HTML>
I am new to JavaScripting and this is my very first script. Well you see I play this online game, and I have a site that I would like to have a members area in. This passwordCode i have been having troubles with. Can someone point me in the right direction?
<HTML>
<SCRIPT LANGUAGE="JScript">
<BODY onload=getpassword()>
function getpassword()
var password = prompt
("Im gonna need to see some ID"), ("xxxxxxxx")
if (password == "assassin") {
document.writln("<BODY><H1>Good your one of us!</H1>
Sorry about that but the boss says we need it.
</BODY>")
else
document.writeln("<BODY><H1>Incorrect</H1>You have attempted to access
our site without registered password. Please leave or
hit your <B>back</B> button and try again. </BODY>")
</SCRIPT>
</HEAD>
</BODY>
</HTML>