Hello
I am trying to find an alternative for JS to locate a page element.
Here is a simple test form I am experimenting with:
Code:
<form name="form1" method="post" action="">
<table width="100%" border="0" cellpadding="0" cellspacing="0">
<tr>
<td><input name="image1" type="text" id="image1" size="30"></td>
</tr>
</table>
</form>
Now in simple JS the field named "image1" can be located or mapped with:
Code:
document.form1.image1.value=...
Ok, now let's assume I need 2 identically named fields in this form like so:
Code:
<form name="form1" method="post" action="">
<table width="100%" border="0" cellpadding="0" cellspacing="0">
<tr>
<td><input name="image1" type="text" id="image1" size="30"></td>
</tr>
<tr>
<td><input name="image1" type="text" id="image1a" size="30"></td>
</tr>
</table>
</form>
Is there anyway to name the <TD> tags identify a different path to each? I know I can use the "getElementById" to do this, bet it seems that older browsers don't recognize this. Any other solutions? Any html tags I can use that can be "named"?
Thanks
nelson