WordPress.org

Ready to get started?Download WordPress

Forums

Why isn't my cutom field values appearing? (1 post)

  1. SlowClicksDotCom
    Member
    Posted 1 year ago #

    I have this custom field for a post:

    key: price
    value: 2000

    I've added this to my loop:

    <div class="buyitnow"><?php $price = get_post_meta($post->ID, 'price', true);
    if ( $price ) { ?>
    Price: $<?php echo number_format($price ,",",",",","); ?>
    <?php } else {} ?></div>

    But all I'm getting is:

    Price: $

Topic Closed

This topic has been closed to new replies.

About this Topic