View Single Post
Old 02-27-2011, 04:02 PM  
DWB
Registered User
 
Industry Role:
Join Date: Jul 2003
Location: Encrypted. Access denied.
Posts: 31,779
Quote:
Originally Posted by harvey View Post
you're over complicating things, just do this:

Code:
<?php if(get_post_meta($post->ID, 'author-comment', true)): ?>
<div style="somestyle"><?php echo get_post_meta($post->ID, 'author-comment', true); ?></div>
<?php endif; ?>
then just use a custom field named author-comment (or whatever) with the text you want and apply the style as you want.

Alternatively, if your theme doesn't use excerpts, then you can simply place the_excerpt() there, so you'll only need to add an excerpt to display that text, and if you don't input anything, then nothing will be displayed.
Bingo, that did the trick.

Thanks everyone.
DWB is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote