I've setup standard custom fields for some products in WooCommerce which are being displayed on each product page on the front end. However, I'd like to hide those fields that don't have a value entered. I've tried some suggestions made elsewhere on this site but they didn't work for me.
This is what I have on the description.php
<div id="customfield-meta">
<?php
// Display Custom Field Value
echo "<ul>";
echo "<li>Catalogue Number: ".get_post_meta( $post->ID, 'catalogue', true )."</li>";
echo "<li>License Type: ".get_post_meta( $post->ID, 'license', true )."</li>";
echo "<li>Width (px): ".get_post_meta( $post->ID, 'iswidth', true )."</li>";
echo "<li>Height (px): ".get_post_meta( $post->ID, 'isheight', true )."</li>";
echo "</ul>";
?>
</div> <!-- end #customfield-meta -->
Any ideas how I could do this? Thank you