input tags with array
Posted
by Dumbledore of flash
on Stack Overflow
See other posts from Stack Overflow
or by Dumbledore of flash
Published on 2010-06-16T18:04:35Z
Indexed on
2010/06/16
18:12 UTC
Read the original article
Hit count: 177
JavaScript
Hi , Recently i am doing a project in which i encountered a strange problem
this is the program which previous programmer did
MPAN
<input name="mpan[]" id="mpan[]" value="" maxlength="2" size="2" > ///this one to read
<input name="mpan[]" id="mpan[]" value="" maxlength="3" size="3">
<input name="mpan[]" id="mpan[]" value="" maxlength="3" size="3">
<input name="mpan[]" id="mpan[]" value="" maxlength="2" size="2"> ///this one to read
<input name="mpan[]" id="mpan[]" value="" maxlength="11" size="12">
i have to read it from a javascript what i did
1) document.getElementById("mpan").value
==> not reading script does not work
2) document.getElementById("mpan[]").value
==> reading first one
3) document.getElementById("mpan[0]").value
==> script does not work
4) document.getElementById("mpan[3]").value
==> script does not work
can any body tell me how to read this from a javascript program
© Stack Overflow or respective owner