WordPress.org

Ready to get started?Download WordPress

Forums

Custom Field Suite
Create a new post (2 posts)

  1. consumedesign
    Member
    Posted 5 months ago #

    <?php
    echo $cfs->form(array(
        'post_id' => false,
        'post_type' => 'order_form',
    ));
    ?>

    I am using the above code for a custom post type (even tried it with 'post') and it doesn't display the form only a submit button is this correct? The submit button when pressed creates a new "post" but is there a way to return the ID so I can then use:

    <?php
    echo $cfs->form(array(
        'post_id' => $return_ID
    ));
    ?>

    To display the form... or is there a way to display the form from the get go (more than just the submit button) and create a new "post" from there?

    http://wordpress.org/plugins/custom-field-suite/

  2. consumedesign
    Member
    Posted 5 months ago #

    Oh hm... if I edit the Field Group in the Admin the restriction under "Placement Rules" of "Post Types" [x order_form] the form shows. I would rather it only display on the custom post type if possible.

Reply

You must log in to post.

About this Plugin

About this Topic