WordPress.org

Ready to get started?Download WordPress

Forums

SuperCPT
[resolved] Output info (3 posts)

  1. Tristan
    Member
    Posted 10 months ago #

    I have added everything I need on the back end (meta boxes, labels, etc).

    Now to output the data... If my custom post type is "cars", would I add this to the content.php file assuming I'm using the TwentyThirteen theme?

    <?php the_scpt_formatted_meta( 'cars' ) ?>

    A bit confused on the output part

    Thanks again!

    http://wordpress.org/plugins/super-cpt/

  2. Tristan
    Member
    Posted 10 months ago #

    Still not sure how to use <?php the_scpt_formatted_meta( '' ) ?>, so used get post meta instead.

  3. Matthew Boynes
    Member
    Plugin Author

    Posted 10 months ago #

    Hi Tristan,
    The usage is, the_scpt_formatted_meta( $meta_key[, $post_id] )

    See https://github.com/mboynes/super-cpt/wiki/Helper-Functions for full documentation on it.

    Using get_post_meta is great too. The only difference is that (the or get)_scpt_formatted_meta knows the field type and (may) format it for you.

Reply

You must log in to post.

About this Plugin

About this Topic

Tags

No tags yet.