Forums

Help using custom fields (2 posts)

  1. pwtimes
    Member
    Posted 1 year ago #

    Using custom fields, how could I impliment the following into my website so that the meta is similar to that of this website: http://www.guardian.co.uk/football/2011/feb/18/ticket-prices-champions-league-final-wembley

    I'd like bullet points under the title before an image with a caption. If anyone could help, I'd be so grateful.

  2. nipponese
    Member
    Posted 1 year ago #

    I use the following php to check if the Key I want to show even exists, then display the Value for the Key

    <?php
          if (get_post_meta($post->ID, 'client', true)){  //If the Key 'client' exists...
                $key_description_value = get_post_meta($post->ID, 'client', true);  //...assign the variable $key_description_value the Value
                echo $key_description_value; //Print the Value to the screen
          }
    ?>

Topic Closed

This topic has been closed to new replies.

About this Topic