I have made the following script to validate a username and password
for entry to a secured site but can't seem to get it to work properly
<script language = "javascript">
/*
*/
function validate(text1,text2,text3,text4)
{
if (text1=1111=text2 && text3=dummy=text4)
load('Latrobe.mdb');
else
{
load('failure.htm');
}
}
function load(url)
{
location.href=url;
}
</script>
<-----Text 1 is the password text 2 is the username----->
<------ Here is the form------>
<form>
<p>ENTER USER NAME :
<input type="text" name="text2">
</p>
<p> ENTER PASSWORD :
<input type="password" name="text1">
<input type="button" value="Check In" name="Submit"
onclick=javascript:validate
(text2.value,"free",text1.value,"javascript") >
</p>
</form>
Is the data being entered in the wrong areas?
I believe the if function is formatted wrong?