Screwy validation
-
For some reason (I’m guessing related to ACF Pro’s recent JS rebuild, but I don’t understand it well enough to find the problem or how to fix it), half my fields aren’t getting validated on the front end form. It appears to be affecting radio, checkbox, datepicker, button group, and file upload fields – they display the little star indicator to show they’re a required field (if they are set so), but do not get an error message or the acf-error class if you try to submit without filling them out and other validation requirements (I’m specifically concerned about file type and size limitations on the upload fields) have no effect whatsoever.
(Text, textarea, number, email, and select fields are working correctly, displaying an error saying “Please fill out this field.” if you try to submit with it blank, and the appropriate error if there’s a format/range/other issue – and these are being counted in the top message “Validation failed. __ fields require attention.”)
If, however, you correctly fill out all the fields that ARE getting validated there and it actually tries to submit it, I’m getting a weird gray “Validation failed” page that lists all the errors you didn’t get on the form itself, except for the file limitations… they seem to only catch if it’s required.
I added the same field group to posts, to see if the issue was with ACF/Gutenberg, but on the back end, everything is validating as expected, so it seems to be isolated to Advanced Forms front-end forms.
I’m running the most recent versions of WordPress and both plugins, multisite enabled, no other plugins activated. Help?
The topic ‘Screwy validation’ is closed to new replies.