JQuery validate get error message below textbox / input element

http://jsfiddle.net/msbUM/ How to get an error message below the textbox / input element?

+3
source share
3 answers

Just add display: block;to label.error:

label.error { 
   float: none; color: red; 
   padding-left: .5em;
   vertical-align: top; 
   display: block;
}โ€‹
+7
source

Apply display:blockerror tags.

+7
source

Another quick fix would be to replace labelas an element of the error with div.

$(document).ready(function(){ 
    jQuery("#frmId").validate({
        errorElement:'div',
        rules: {
        // RULES //
        },
        messages: {
        // MESSAGES //
        } 
    });
});
+1
source

All Articles