If you've used Dojo and the Dijit library to add field validation to HTML forms then you may have ended up with something like this:
<input required="false" name="Email" invalidMessage="Enter your email address" dojoType="dijit.form.ValidationTextBox" />
All very well. Things work. Until, that is, browsers start to implement the new HTML5 "required" attribute added to the input element.
I found this out this week while supporting a site I've inherited from another developer who created it many moons ago. Long before even HTML4 was being ratified. The site still works but not in IE10.
In the case of the above field IE10 insists, correctly, that a value be entered. As far as the HTML5-supporting IE10 is concerned, it is a required field. Even if the value of the attribute says false.
This is because the required attribute is a "boolean attribute". Meaning that, if the attribute is there at all, it's considered "on" or "true". Specifying a value of "false" has no effect. To turn if off you have to remove the attribute.
So, the fix is simple. For non-required input elements just miss the required attribute off, like so:
<input name="Email" invalidMessage="Enter your email address"
This way, both IE10 and Dojo's validation routines are happy to co-exist.
Bear in mind though that, from now on, the correct way to add custom attributes to any HTML element is to do so with the "data-" prefix. So the above field could be:
<input data-required="false" name="Email" data-invalidMessage="Enter your email address" data-dojoType="dijit.form.ValidationTextBox" />
Although, obviously, that won't work with existing versions of Dojo unless you alter the source code. But, if you're adding your own attributes to your own HTML then use "data-". If not, and you insist on making your own attributes without the data- prefix, just make sure you don't use a word that won't, one day, become a bona-fide attribute.