The tagName that is relevant here is "input", not td. That will get you what you're looking for.
It's almost a cliche on StackOverflow, but I suggest you take a look at JQuery. JQuery allows you to treat your html as a database and query it to get this kind of stuff. If your markup was like this:
You could get the value like this:
$("#id").value();
If you wanted to get the value of the maxlength attribute on it, you could do this:
$("#id").attr("maxlength");
Much more fun than digging through element arrays.