Hello
I am attempting to render ACF forms on the frontend.
Here is some sample code I am using:
add_action('genesis_entry_content', 'checklist_1_single');
function checklist_1_single() {
acf_form();
}
(this is in a single-[my-content-type].php template override).
In functions.php I have the following:
add_action('init', 'acf_form_head');
With these two bits of code, the form renders fine.
However when I submit the form it pushes an AJAX submission to admin.ajax.php
which promptly processes the submission and performs a 302 redirect to /my-path??updated=true
.
That’s nice, but this just causes the form to hang. Shouldn’t the AJAX be sending a message back to some callback in ACF to prompt it to send the user to the given return page, rather than simply 302ing the ajax request?
Also, I tried removing
add_action('init', 'acf_form_head');
from functions.php and the submission works, but other things like conditional fields, wysiwyg etc don’t work properly.
I’m running WordPress 4.2.1 with ACF Pro 5.2.3 on top of Genesis 2.1.2.
Any assistance appreciated