Hi there,
I’m trying to create a front end form, in order to create a newsletter subscription.
I’ve searched online and found out that acf_form() supports front end guest user post (http://support.advancedcustomfields.com/forums/topic/guest-submit-posts-front-end-form/)
But it is not working on my page.
The code:
<?php acf_form(array(
‘post_id’ => ‘new_post’,
‘new_post’ => array(
‘post_type’ => ‘newsletter’,
‘post_status’ => ‘publish’
),
‘post_title’ => true,
‘submit_value’ => ‘Inscrever’
)); ?>
Can anyone help me?
Thank you!
When you say the code is not working, do you mean the form is not displayed or that the new post is not created?
The new post isn’t created, but that’s because I forgot to to include acf_form_head() at the top of my template.
Thanks anyway John!