Custom Header on Posts Page Not Working
-
Hi there, Im using the following code to display a different header on each of my wordpress pages:
<div class="banner"> <?php if(get_post_meta($post->ID, 'banner', true)) : ?> <img src="<?php echo get_post_meta($post->ID, 'banner', true); ?>" /> <?php else : ?> <?php the_title(); ?> <?php endif; ?> <div>
To insert a new header image I am calling “banner” within a page’s custom fields.
However, it doesn’t seem to work for posts as well. I have tried calling “banner” from inside my posts, but still nothing. I was just wondering if anyone knew how to adapt the code to include a custom header within posts as well. I would be very gratefull for your help.
Thanks
Viewing 3 replies - 1 through 3 (of 3 total)
Viewing 3 replies - 1 through 3 (of 3 total)
- The topic ‘Custom Header on Posts Page Not Working’ is closed to new replies.