Created
December 20, 2012 19:14
-
-
Save StevePotter/4347860 to your computer and use it in GitHub Desktop.
jquery validator global settings for twitter bootstrap horizontal forms
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$.validator.setDefaults({ | |
highlight: function(label) { | |
return $(label).closest(".control-group").addClass("error"); | |
}, | |
success: function(label) { | |
return label.hide().closest(".control-group").removeClass("error"); | |
}, | |
errorClass: "help-inline", | |
validClass: "" | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment