Advertisement
nellieg

Edited Header.php

Nov 21st, 2011
58
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.83 KB | None | 0 0
  1. <div id="site-description"><?php bloginfo( 'description' ); ?></div>
  2. <?php if( !is_page_template( 'PopUp' ):?>
  3. <?php
  4. // Check if this is a post or page, if it has a thumbnail, and if it's a big one
  5. if ( is_singular() && current_theme_supports( 'post-thumbnails' ) &&
  6. has_post_thumbnail( $post->ID ) &&
  7. ( /* $src, $width, $height */ $image = wp_get_attachment_image_src( get_post_thumbnail_id( $post->ID ), 'post-thumbnail' ) ) &&
  8. $image[1] >= HEADER_IMAGE_WIDTH ) :
  9. // Houston, we have a new header image!
  10. echo get_the_post_thumbnail( $post->ID );
  11. elseif ( get_header_image() ) : ?>
  12. <img src="<?php header_image(); ?>" width="<?php echo HEADER_IMAGE_WIDTH; ?>" height="<?php echo HEADER_IMAGE_HEIGHT; ?>" alt="" />
  13. <?php endif; ?>
  14. <?php endif;?>
  15. </div><!-- #branding -->
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement