1
I use Jquery Validate to validate inputs, but when validation fails, an error message label is created next to the input.
My goal is to have this label shown below the input, without changing the position of the inputs next to the validated input, but when I use the CSS property 'display: block', the inputs on the side are pushed down, as if there were a '< br >' between the inputs and the error label generated by the validation.
Following demonstration
Prior to validation: After validation:
The CSS code of the error label is very simple:
label.error {
font: 11px arial;
margin-left: 2px;
display: block; }
If my question is incomplete, please let me know that I will supplement the question as soon as possible.
How did it appear before you put display block? Above the other inputs on the side?
– Sam
You can post HTML only for this part of these 3 fields?
– Sam
You tried with
display:inline-block
?– hugocsl