Home › Forums › ACF PRO › Are there JS triggers for when an acf_form() is submitting/completed/failed? › Reply To: Are there JS triggers for when an acf_form() is submitting/completed/failed?
Perfect, thank you! The first part of your answer solved my question. I kept my .click()
method and then added the following:
acf.add_filter('validation_complete', function( json, $form ){
if (json.errors) {
showLoadingBlocker(false);
}
return json;
});
I realise I couldn’t do anything exclusively with JS after the form submission had gone through and the page redirected, but all I was really looking for was that kind of JS error handler.
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.