WordPress.org

Support

Support » Themes and Templates » [Resolved] Header image

[Resolved] Header image

  • How do I keep the header image from displaying on every page. I only want the header on the front page.
    Thanks for you help.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Theme Author krusze

    @kruszepl

    Hey. In content-extensions.php find this:
    <?php $header_image = get_header_image();
    if ( ! empty( $header_image ) ) : ?>
    <img src=”<?php echo esc_url( $header_image ); ?>” width=”<?php echo HEADER_IMAGE_WIDTH; ?>” height=”<?php echo HEADER_IMAGE_HEIGHT; ?>” alt=”” class=”header-image” />
    <?php endif;

    and change to:

    <?php $header_image = get_header_image();
    if ( ! empty( $header_image ) && is_front_page() ) { ?>
    <img src=”<?php echo esc_url( $header_image ); ?>” width=”<?php echo HEADER_IMAGE_WIDTH; ?>” height=”<?php echo HEADER_IMAGE_HEIGHT; ?>” alt=”” class=”header-image” />
    <?php }

    Theme Author krusze

    @kruszepl

    Hope this one abobe helped you.
    Marked as resolved.

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘[Resolved] Header image’ is closed to new replies.