Home › Forums › Front-end Issues › Creating Front End Post with Flexible Content › Reply To: Creating Front End Post with Flexible Content
Sorry but I still couldn’t figure out your advice.
This ['field_55ee67fc0ce35']
is to let user select the no of column per row. So if they select 3 then it will be 3 column. If they select 2 it will become 2 column and so on. This was supposed to behave exactly the same page builder for the front end form. I get the idea from the video in here.
I was thinking of simplifying this. Will it be simpler if my post has flexible content layout and I insert it into the post custom field rather than the content.
What will I need to replace/add
$post = array(
'post_type' => 'post', // Your post type ( post, page, custom post type )
'post_status' => 'publish', // (publish, draft, private, etc.)
'post_title' => wp_strip_all_tags($_POST['acf']['field_55e95e746593e']), // Post Title ACF field key
'post_content' => $_POST['acf']['field_55e95e8b6593f'], // Post Content ACF field key
);
to do so?
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.