Viewing 1 replies (of 1 total)
  • Thread Starter aptharsia

    (@aptharsia)

    If anyone else is curious…

    <?php
    global $post;
    $bathrooms = get_post_meta($post->ID, 'bathrooms', true);
    if ( !empty($bathrooms) ) { echo '<li>Baths: [bathrooms]</li> ' ; }
    ?>

    Of course, change the word bathrooms to whatever value you have, but it worked for me.

Viewing 1 replies (of 1 total)
  • The topic ‘hide if empty when using shortcodes?’ is closed to new replies.