Forums

The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums Other WordPress – Getting specific custom field value Re: WordPress – Getting specific custom field value

#89773
TheDoc
Member

This might work, though I haven’t tried it:


$amount = get_post_meta($post->ID, 'amount', true);

if ($amount == 'Funded') {
// do something
}
?>

This is just a slightly modified version of one of the snippets available here: https://css-tricks.com/snippets/wordpress/using-custom-fields/