Trebor Almasy Posted February 8, 2014 Share Posted February 8, 2014 I was reading about the HTML5 form attributes here:http://www.w3schools.com/html/html5_form_attributes.aspSpecifically the part: Tip: To refer to more than one form, use a space-separated list of form ids.But for the life of me I can't get it to work.I know you can easily do it with Javascript (as I have it now), but if you can do it just as easily with HTML, I figure why not.Any ideas why this may not be working (I tried both Chrome and FF). Link to comment Share on other sites More sharing options...
Ingolme Posted February 9, 2014 Share Posted February 9, 2014 (edited) I'm not sure what browser you're testing in, but Internet Explorer doesn't support the form attribute. I believe the value is case sensitive, so "Form1" would be different than "form1" Well, I am testing in Firefox and it seems that assigning an input to multiple forms isn't supported. I guess there's nothing to do about it. Here's Mozilla's description: https://developer.mozilla.org/en-US/docs/Web/HTML/Element/Input Form The form element that the input element is associated with (its form owner). The value of the attribute must be an id of a <form> element in the same document. If this attribute is not specified, this <input> element must be a descendant of a <form> element. This attribute enables you to place <input> elements anywhere within a document, not just as descendants of their form elements. An input can only be associated with one form. Edited February 9, 2014 by Ingolme Link to comment Share on other sites More sharing options...
Trebor Almasy Posted February 9, 2014 Author Share Posted February 9, 2014 Yeah after more testing I couldn't get it to work in any browser (Opera, Chrome, Safari, Firefox, IE). I'm assuming the info was incorrect. Link to comment Share on other sites More sharing options...
Ingolme Posted February 9, 2014 Share Posted February 9, 2014 The HTML 5 draft goes through many changes. It's possible that at one point it was going to allow multiple forms. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now