i have a custom post type called ‘our athletes’. on that custom post type is a custom metabox with several fields in it, one of which is checkbox called ‘featured’. if they check that box then i want the info to show up in the header.
i don’t know php very well, but tried this and got no where:
<?php $checkedfeatured = get_post_meta( get_the_id(), '_cmb_featured_checkbox', true ); if ($checkedfeatured) { get_template_part('content','featured'); } ?>