jQuery Custom Label Validation -
jQuery Custom Label Validation -
i'm wanting manipulate positioning of jquery validate plugin label positioning on submission.
when view form, press submit , notice labels have beingness replaced validation plugin. ok i'm not wanting double in labels.
i'm wanting error message replace existing label text 1 label handles input used , error message. i'm unsure if possible.
here current validation rules:
validation: function () { $('form').validate({ rules: { "email": { required: true, email: true }, "name": { required: true } } }); } here working illustration of have: jsfiddle
i've adjusted fiddle adding css
fieldset label:nth-of-type(even) { display:none; } when click submit, sec label isn't displayed.
update question in comment: i've made css adjustment this, fiddle:
fieldset label[style*='display: none'] + label { display:block; color:#007c92; top:15px; position:absolute; left:23px; font-size:0.7em; font-weight:bold; } i'm not sure if that's have - name email keeps displaying label on top of right entries. adjusted in case should done email. without css adjustments, looks validate plugin display label in input, display error message in label in case of error , sets label display:none in case of right entries. perchance there's alternative / setting in validate plugin have functionality without using kind of workaround, maybe checked that.
jquery jquery-plugins jquery-validate
Comments
Post a Comment