WordPress.org

Support

Support » Plugins and Hacks » Create a new post

Create a new post

  • consumedesign
    Participant

    @consumedesign

    <?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/

Viewing 1 replies (of 1 total)
  • consumedesign
    Participant

    @consumedesign

    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.

Viewing 1 replies (of 1 total)
  • The topic ‘Create a new post’ is closed to new replies.