Are HTML buttons with no values submitted in a form? -
if have
<button class="button yellow" type="submit" name="button">log in</button>
and submit it, gets posted server button has name no value attribute?
the reason ask i'm parsing html forms, , need post named values send data server. got others covered, wasn't sure button.
according html spec, button's value either determined value
attribute or empty string. button's value submitted form if button has name , used initiate form submission. if button in example clicked, resultant submission be:
"button=" (quotes added)
some browsers (mainly older ie versions) have incorrect implementations of button behaviour either set value button's contents or submit button values regardless of initiation source.
Comments
Post a Comment