• Resolved SoloAnt

    (@soloant)


    This might be a lame question but I’m not seeing anything on how to have the data that’s input into the custom fields in the meta boxes be able to be displayed in the template files of the theme files to output the info on the front end. Make sense?

    I currently use Custom Content Type Manager and when creating a custom field it outputs a little code (e.g. <?php print_custom_field(‘custom_field_name’); ?> ) that can be inserted in the theme files.

    How do you do that with your plugin and extentions? I’m not a programmer/developer at all I’m a designer that makes due with php somehow. hahaha.

    But I’m looking to possibly switch to another plugin and I came across yours.

    Thanks
    Sol

    https://www.ads-software.com/plugins/meta-box/

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Anh Tran

    (@rilwis)

    Hi,

    That actually is a good question :).

    The Meta Box uses a similar simple function to display field value in the frontend:

    <?php echo rwmb_meta( $key ); ?>

    You can just insert it in the template files of your theme.

    For complicated fields (like image upload), there’re several arguments for this function, please follow the instruction in the documentation.

    Thread Starter SoloAnt

    (@soloant)

    Got it, thanks for the quick reply.

    Are you thinking about adding custom content types and taxonomies at all?

    I’m trying to decided on an all inclusive plugin for this or multiple to do that. Do you have any insights or thoughts on this by chance?

    Thanks
    Sol

    Plugin Author Anh Tran

    (@rilwis)

    Hi,

    I think adding custom content types and taxonomies are easy with register_post_type and register_taxonomy functions. I mean it’s really simple because it needs only 1 function call. You can just copy the code to paste into your theme (or you can use generatewp.com website to generate code for you), there’s no need for plugins to do that. It might improve your website performance, too (because it won’t load other plugins’ code just to do a simple thing).

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Theme File Templates’ is closed to new replies.