Home › Forums › Backend Issues (wp-admin) › Set novalidate on a acf form in admin
I have a form containing some url fields. The issue is that Safari validates html5 input fields BEFORE the user can save a draft og publish a post. When the field is in another tab, the user can’t see that Safari can’t validate the field and the user is stuck :-/
It is the same for email fields.
ACF is set to validate both the email and url fields when the post is published which is great in Chrome.
I would like Safari to do the same: Not validate the fields before submitting the form, so ACF can validate the fields.
Setting “novalidate” on the form works. But how can I set this attribute on a ACF generated form when creating a post? Is there a filter or a setting I can use to make ACF set this attribute on the form?
One thing I just thought of that you might want to consider is that I think ACF might depend on browser validation is some cases, but I’m not 100% certain of that.
Check. I can see that Safari does some validation that Chrome doesnt. I will keep that in mind and check 🙂
Hi John,
I can see that the acf_form is for a frontend form. What I need is to add novalidate to a form when editing a post in the admin.
I register the field group for the post with acf_add_local_field_group and then ACF generates the form.
Is there a way to add novalidate to this kind of form?
You must be logged in to reply to this topic.
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.