Placeholders.js
Placeholders.js copied to clipboard
Fix #75 - Bug with form submit handler not being attached in some cases
According to MDN, the form
property of an HTMLInputElement may be the id of any form in the current document or the containing form HTMLFormElement itself.
The second case was previously not accounted for, only adding the submit handler when a string was present. This was breaking functionality on IE9.
All credit for this goes to @littletijn: http://git.io/vRYQX only submitting this myself as they have not responded to the issue, and (s)he doesn't look to be active.
Fixes #75
Works for me!
@littletijn No problem! Thanks for finding the issue. :smiley:
@jamesallardice Is there anything preventing this from being merged? We've been using this 'patched' version internally across a few sites without any ill-effect.
I rebuild your code and update grunt to v 1