Hi, im using Custom Taxonomies in my theme, for example:
<?php echo get_the_term_list( $post->ID, 'people', 'People: ', ', ', '' ); ?>
Is it possible to do a conditional statement to output some code only if that taxonomy has a value/term entered in it in the admin posts page.
IF taxonomy has a value then output this:
<dt>Gender: </dt> <dd><?php echo get_the_term_list( $post->ID, 'gender', '', ' / ', '' ); ?><span></span></dd>
ELSE (if it has no values) then output NOTHING!
Is this possible? Thanks in advance.
- The topic ‘Custom Taxonomy Conditional – Output code only if taxonomy has a value’ is closed to new replies.