WordPress.org

Make WordPress Core

Changeset 25626


Ignore:
Timestamp:
09/25/2013 04:58:43 PM (7 years ago)
Author:
lancewillett
Message:

Twenty Twelve: simplify header image check, props obenland. Closes #25400.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-content/themes/twentytwelve/header.php

    r25521 r25626  
    4646        </nav><!-- #site-navigation -->
    4747
    48         <?php $header_image = get_header_image();
    49         if ( ! empty( $header_image ) ) : ?>
    50             <a href="<?php echo esc_url( home_url( '/' ) ); ?>"><img src="<?php echo esc_url( $header_image ); ?>" class="header-image" width="<?php echo get_custom_header()->width; ?>" height="<?php echo get_custom_header()->height; ?>" alt="" /></a>
     48        <?php if ( get_header_image() ) : ?>
     49        <a href="<?php echo esc_url( home_url( '/' ) ); ?>"><img src="<?php header_image(); ?>" class="header-image" width="<?php echo get_custom_header()->width; ?>" height="<?php echo get_custom_header()->height; ?>" alt="" /></a>
    5150        <?php endif; ?>
    5251    </header><!-- #masthead -->
Note: See TracChangeset for help on using the changeset viewer.