When you set the the custom phone number fields to *required and select just the country code but no phone number in the text field a user can still submit the form causing incomplete data on the backend. Full phone numbers are missing even though the fields are required.
Also when I select the default value to US it reverts to canada even after saving and applying the changes. It always defaults to +1CAD. I have to leave that drop down set to null “-” because it always defaults back to +1CAD on the front end.
Thank you for any help!
Another Form field validation bug I found is if you have “I agree field” enabled and submit the form with unchecked “I agree” field – the error label is placed into the checkbox label – it gets nested and looks not good.
A solution could be to set “errorPlacement” option when you call this.$element.find(‘form’).validate(); and place the error label outside the checkbox label.
Hi pradev, can you please paste the screenshot link to that issue?
Sure, here you check out:
The error label is appended exactly after the checkbox input and before “I agree with…” text. You could avoid this with errorPlacement plugin option.
I could also suggest you to wrap the checkbox text into span element for those people who want to play with css and create beautiful custom checkbox like in the screenshot below:
Hi, thanks for reporting we will fix that label issue. Regarding country code number well it forms single field so we can add the something like has to be number with more then 4 digits. Would that be ok for you?
You mean to create a separate field for country code? Sounds good.
Well it will be required to enter more than 3 numbers there.