Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Text Box Validation text boxes have same name

Status
Not open for further replies.

NikkP

MIS
Sep 25, 2007
5
US
Hi, im doing a final year computing project at uni i need to be be able to check that some text boxes are not empty the problem is the text boxes are called the same names..can anyone help.... my html code is below

<html>
<head>
<link rel=&quot;stylesheet&quot; type=&quot;text/css&quot; href=&quot;standard.css&quot;>
<script language=&quot;javascript&quot; src=&quot;scripts.js&quot;>

</script>
</head>
<body>
<table cellpadding=&quot;3&quot; cellspacing=&quot;0&quot; border=&quot;0&quot; height=&quot;600&quot; width=&quot;800&quot; id=&quot;theme&quot;>

<tr>
<td colspan=&quot;6&quot; height=&quot;50&quot; id=&quot;studentheading&quot; width=&quot;800&quot;>
Coursework enter page for <%=module%>
</td>
</tr>

<tr height=&quot;30&quot; width=&quot;800&quot;>
<td></td>
<td>Student Name</td>
<td>Student Surname</td>
<td>ModuleID</td>
<td>CW No.</td>
<td>CW Mark(%)</td>
</tr>
<form action=&quot;cwentered.asp&quot; method=&quot;post&quot; name=&quot;enteredcw&quot;>
<%do until objRs.EOF%>

<tr height=&quot;10&quot;>
<td><input type=&quot;hidden&quot; name=&quot;studentid&quot; value=&quot;<%=objRs(2)%>&quot;></td>
<td><input readonly type=&quot;text&quot; name=&quot;studentforname&quot; value=&quot;<%=objRs(3)%>&quot;></td>
<td ><input readonly type=&quot;text&quot; name=&quot;studensurname&quot; value=&quot;<%=objRs(4)%>&quot;></td>
<td ><input type=&quot;text&quot; name=&quot;moduleid&quot; value=&quot;<%=module%>&quot;></td>
<td><input type=&quot;text&quot; name=&quot;cwnumber&quot; maxlength=&quot;1&quot; onKeypress=&quot;if (event.keyCode < 48 || event.keyCode > 57) event.returnValue = false;&quot;></td>
<td><input type=&quot;text&quot; name=&quot;cwmark&quot; maxlength=&quot;3&quot; onKeypress=&quot;if (event.keyCode < 48 || event.keyCode > 57) event.returnValue = false;&quot;></td>
<%
objRs.MoveNext%>
</tr>
<%loop

objRS.close

conn.close

%>

<tr>
<td colspan=&quot;6&quot; align=&quot;right&quot; valign=&quot;top&quot;><input type=&quot;submit&quot; value=&quot;Submit&quot;></td>
</tr>
</form>
</table>



</body>
</html>

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top