Add a fix for attributes novalidate and formnovalidate

In some circumstances ```$.attr("novalidate", "novalidate")``` causes an error and ```$.attr("formnovalidate") !== undefined``` causes an undesirable behavior.