Title: 2 headers? Quick question
Last modified: August 18, 2016

---

# 2 headers? Quick question

 *  [dekard](https://wordpress.org/support/users/dekard/)
 * (@dekard)
 * [20 years, 6 months ago](https://wordpress.org/support/topic/2-headers-quick-question/)
 * With the help of Tyler from ontherocks comics, I’ve added this to my header.php
   for my theme and gotten the comics above the news.
 * <?php
    $gposts = get_posts(‘numberposts=1’); foreach ($posts as $post) : ?>
 * <?php echo ‘<img src=”‘ ?>
    <?php the_time(‘Y-m-d’) ?> <?php echo ‘.gif”/>’ ?
   >
 * <?php
    endforeach; ?>
 * My only issue now is, I’d like the images to only show for the news posts, not
   new pages. If I post a page today that doesn’t have a comic it shows a red x,
   because it’s looking for comic with todays date, I’d like to have a seperate 
   header for pages that doesn’t include the php above, but unsure how to use 2 
   different headers.

Viewing 3 replies - 1 through 3 (of 3 total)

 *  Thread Starter [dekard](https://wordpress.org/support/users/dekard/)
 * (@dekard)
 * [20 years, 6 months ago](https://wordpress.org/support/topic/2-headers-quick-question/#post-280425)
 * you can see it in action here;
    [http://www.gamesmademe.com](http://www.gamesmademe.com)
 * A page with the red x: (since theirs no comic today)
    [http://www.gamesmademe.com/?page_id=12](http://www.gamesmademe.com/?page_id=12)
 *  [moshu](https://wordpress.org/support/users/moshu/)
 * (@moshu)
 * [20 years, 6 months ago](https://wordpress.org/support/topic/2-headers-quick-question/#post-280445)
 * I don’t see any “red x” in FF, but I can see it in IE.
    Can’t you just put the
   above code in an if_statement, saying “if is not page > do this, else do nothing”?
 *  Thread Starter [dekard](https://wordpress.org/support/users/dekard/)
 * (@dekard)
 * [20 years, 6 months ago](https://wordpress.org/support/topic/2-headers-quick-question/#post-280474)
 * possibly, just not sure how to accomplish it. Thanks.

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘2 headers? Quick question’ is closed to new replies.

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 3 replies
 * 2 participants
 * Last reply from: [dekard](https://wordpress.org/support/users/dekard/)
 * Last activity: [20 years, 6 months ago](https://wordpress.org/support/topic/2-headers-quick-question/#post-280474)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
