Display two custom values from a post
How about: $thumb = get_post_meta( $post_id, ‘thumb’, true ); $url = get_post_meta( $post_id, ‘website’, true); echo “<a href=”https://wordpress.stackexchange.com/questions/24970/$url”><img src=”$thumb” /></a>”; The get_post_meta() function is ideal when you know ahead-of-time the names of the fields you want to retrieve. Setting the third parameter to true tells it that you want to return a single value, and … Read more