I'm using woocommerce plugin in my wordpress web site. In Admin panel for products I've added few custom fields as shown bellow:
On my shop page, I want to print the custom field values, and I use the following code (
my code is inside the
<?php echo get_post_meta(get_the_ID(), 'flavour1Title', true); ?>
But I get empty string for any retrieved value.
Please can someone explain me what is wrong with my code?