Hello,
I have a website that pulls in a different bit of content for each page and I have been using a custom field with this code:
<?php if(get_post_meta($post->ID, "quote", true)); ?>
<div id="rhtquote"><?php echo get_post_meta($post->ID, "quote", true); ?></div>
<?php ?>
The problem I am having however is that the rhtquote div id pulls in a background image and this div persists even if there if no "quote" custom field set up for that page, obviously.
How can I code this so that if there isn't a custom field added for the page then nothing is added, including those div tags?
Much thanks,
Brandon