New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ERROR "success:" and "errorPlacement:" at the same time will not work #1758
Comments
Maybe this example can be helpful: |
This comment has been minimized.
This comment has been minimized.
In my case errorPlacement callback was called only the first time. Subsequent calls were ignore because the error element was never removed from the DOM on valid cases. I hope this helps you. |
Hi @prochafilho Sorry about that, we didn't had the time to look into this issue and the bot closed it after all this time of inactivity. I'll reopen it and mark it as a bug. Hopefully I or someone else will have the time to look into it and why not provide a fix. Thanks for the reminder. |
Use "highlight/unhighlight" instead of your "success/errorPlacement" function |
This issue lacks verification. Please provide a reproduction link. |
Subject of the issue
If i use
success:
anderrorPlacement:
at the same time jquery changes to the dom will work only the first time but not on any subsequent changes of the input field!Your environment
jquery-validate
: 1.15Steps to reproduce
I do have a simple bootstrap form
and this related java script
Expected behaviour
Remove old classes and span tag and add new classes and span tag on ERROR or SUCCESS.
Actual behaviour
The DOM elements are changed accordingly to the first input in the input field but then stay in this stage forever.
Additional Info
It is also pretty strange that ERROR is always executed before SUCESS?:
The text was updated successfully, but these errors were encountered: