hiii... i am writing an application in jsp to create a login form. but it shows an error : string not properly closed at line 7.
also the java script included doesnot show any error message ...
here is the code:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title>REQUIRED FIELD SCRIPT</title>
<SCRIPT LANGUAGE="javascript">
<!-
function isempty(theField)
{
if(thefield.value=="")
{
return true;
}
else {
return false;
}
}
function isRequired(thisForm)
{ var Empty= false;
if(isEmpty(thisform.loginid))
{
alert("THIS FIELD IS REQUIRED. PLEASE FILL IT!!");
Empty = true;
}
if (Empty== false && isEmpty(thisForm.password)== true)
{
alert("THIS FIELD IS REQUIRED. PLEASE FILL IT!!");
Empty = true;
}
if(Empty== false)
{
document.thisForm.submit();
}
}
//->
</SCRIPT>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css">
<!--
.style3 {
font-family: Arial, Helvetica, sans-serif;
font-size: 24px;
font-weight: bold;
color: #FF3300;
}
.style4 {
font-size: 36px;
color: #FF0000;
}
</style>
</head>
<body>
<form name="thisForm" method="post" action="">
<table width="1646" height="120" border="1">
<tr>
<td width="1636" height="114" bordercolor="#31CEAE" bgcolor="#31CEAE"><table width="1218" height="49" border="0" bordercolor="#00CCFF">
<tr>
<td width="116" bgcolor="#00CCFF"><input name="imageField" type="image" src="file:///K|/project/Iocl_logo.jpg" width="100" height="100" border="0"> </td>
<td width="1092" bgcolor="#31CEAE"> <blockquote>
<blockquote>
<blockquote class="style3 style4">INDIAN OIL COOPERATION </blockquote>
</blockquote>
</blockquote></td>
</tr>
</table></td>
</tr>
</table>
<table width="1642" border="0" bordercolor="#31CEAE">
<tr>
<td width="403" height="255" bgcolor="#31CEAE"><blockquote>
<blockquote>
<blockquote>
<blockquote>
<p><a href="file:///K|/project/IOCL%20PROJECT%20PAGE/newuser.htm" title="newuser" class="style3">New User?</a></p>
</blockquote>
</blockquote>
</blockquote>
</blockquote></td>
<td width="1229" bgcolor="#31CEAE"><table width="573" border="0">
<tr>
<td width="88" height="48"> </td>
<td width="222"><blockquote>
<p><strong>LOGIN ID </strong></p>
</blockquote></td>
<td width="249"><p>
<input name="loginid" type="text" id="loginid">
</p></td>
</tr>
<tr>
<td height="28"><blockquote> </blockquote> <blockquote>
<p> </p>
</blockquote></td>
<td height="28"><blockquote>
<p><strong>PASSWORD</strong></p>
</blockquote></td>
<td height="28"><p>
<input name="password" type="password" id="password">
</p></td>
</tr>
<tr>
<td height="29" colspan="2"> </td>
<td height="29"> </td>
</tr>
<tr>
<td height="57"> </td>
<td><blockquote>
<blockquote>
<p>
<input name="Reset" type="reset" value="RESET">
</p>
</blockquote>
</blockquote></td>
<td><blockquote>
<blockquote>
<p>
<input name="login" type="submit" id="login" value="LOGIN" onClick="isRequired(this.Form)">
</p>
</blockquote>
</blockquote></td>
</tr>
</table></td>
</tr>
</table>
<table width="1642" height="2327" border="1">
<tr>
<td width="1632" height="2321" bordercolor="#31CEAE" bgcolor="#31CEAE"> </td>
</tr>
</table>
</form>
</body>
</html>