Answers for "woocommerce get post meta"

PHP
1

wp get meta field value

<?php $key_1_value = get_post_meta( get_the_ID(), 'key_1', true ); ?>
Posted by: Guest on June-23-2020
0

wp get meta field value

<?php if ( get_post_meta( get_the_ID(), 'thumb', true ) ) : ?>
    <a href="<?php the_permalink() ?>" rel="bookmark">
        <img class="thumb" src="<?php echo esc_url( get_post_meta( get_the_ID(), 'thumb', true ) ); ?>" alt="<?php the_title_attribute(); ?>" />
    </a>
<?php endif; ?>
Posted by: Guest on June-23-2020
0

woocommerce get post meta

get_post_meta( int $post_id, string $key = '', bool $single = false )
Posted by: Guest on July-15-2021

Code answers related to "woocommerce get post meta"

Browse Popular Code Answers by Language