Wednesday, September 22, 2010

HTML nested forms

To my surprise it seems that HTML does not support nested forms in form or

<form action="" method="POST">
<br/>Outer Age <input type="text" name="age">
<form action="" method="POST">
<br/>Inner Age <input type="text" name="age">
<br/><input type="submit" value="Inner" id="inner">
</form>

<br/><input type="submit" value="Outer" id="outer">
</form>


The guys from w3.org are saying:

"There can be several forms in a single document, but the FORM element can't be nested."

Well, I tried to do it and to my surprise the outer form submit is completely ignored.

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.