Open liuanxin opened 5 years ago
I created a MR on cdnjs and waiting to be merged. Than the latest version of jquery-validation-engine will be available on cdnjs.
can you tell me the problem with latest jquery version and 2.6.4?
In addition, after I added the following style, a single error prompt will be output to a line(as in the above figure, * Not a valid
and integer
are output in two lines).
.formError { white-space: nowrap; }
In this way, the position on the upper right is consistent every time the request is made. If not, the first validate error will be slightly lower, then click on the animation to move the prompt.
Of course, I am not sure if this is intentional
jquery 3.4.1: https://liuanxin.github.io/version/3.4.1.html fail jquery 3.2.1: https://liuanxin.github.io/version/3.2.1.html success
$.validationEngine.defaults.scroll = false
and $form.validationEngine('validate', { scroll: false })
are not in effect in query 3.2.1, { promptPosition : "topLeft" }
is also, can only be used on each attribute data-prompt-position="topLeft"
It seems that the generation point of the error prompt has a problem when getting the position. The same problem is also found in the datetimepicker
. The location goes to the top of the page.
@dennybrandes
I tried you links but i can't see any error. Prompt is on correct position. Where can i see the bug exactly?
I'm sorry, I did not express clearly
I modified the code to the following
var flag = $form.validationEngine('validate', { promptPosition: "topLeft", scroll: false });
if (!flag) {
return;
}
The final error message is still in the default position(topRight). If I want to make the error appear on the topLeft, I have to use data-prompt-position="topLeft"
on each form element.
In addition, if the first error is not in the visible area, scroll: false
will not take effect, and it will still scroll. Of course, this does not take effect when validate
Don't consider putting 3.1.0 on cdn?
Now the latest 2.6.4 version on cdn, there is a problem with the latest 3.4.1 version of jquery