N
Narlen
Hi there
I would like to password protect (or "directory listing denied") my website.
I am using the following code. The problem is that if people choose "view
page source" in any web browser it shows the password. Can anyone give me a
code that would hide the password? Thanks a lot for your help.
Here is the code:
<script language="javascript">
<!--//
function pasuser(form) {
if (form.pass.value=="michael2") {
location="index2.html"
} else {
alert("Invalid Password")
}
}
//-->
</script>
<tr><td><h1><i><b>Password:</b></i></h1></td><td><form name="login"><input
name="pass"
type="password"></td></tr>
<tr><td><input type="button" value="Login"
onClick="pasuser(this.form)"></td><td><br>
I would like to password protect (or "directory listing denied") my website.
I am using the following code. The problem is that if people choose "view
page source" in any web browser it shows the password. Can anyone give me a
code that would hide the password? Thanks a lot for your help.
Here is the code:
<script language="javascript">
<!--//
function pasuser(form) {
if (form.pass.value=="michael2") {
location="index2.html"
} else {
alert("Invalid Password")
}
}
//-->
</script>
<tr><td><h1><i><b>Password:</b></i></h1></td><td><form name="login"><input
name="pass"
type="password"></td></tr>
<tr><td><input type="button" value="Login"
onClick="pasuser(this.form)"></td><td><br>