I have the following code:
I'm getting sytax errors on lines 11 and 25.
1) What's wrong with my syntax?
2) Are there any sites that let you plug in a script and they help you debug them?
Thanks!
Dot
Code:
<html>
<head>
<title>Untitled</title>
<script>
function checkName(){
//alert("Hi!")
var UserName = document.myForm.UserName.value;
if (UserName == "ME") {
alert("Hello, YOU!!!");
else
alert("Hi, " + UserName + "!");
}
return (true);
}
//-->
</script>
</head>
<body>
<form name="myForm" onSubmit="return checkName()">
<input type ="text" name="UserName">
<input type ="submit" value="SUBMIT">
<input type="reset">
</form>
</body>
</html>
1) What's wrong with my syntax?
2) Are there any sites that let you plug in a script and they help you debug them?
Thanks!
Dot