WordPress.org

Support

Support » Themes and Templates » [Resolved] How to add an extra image to the header

[Resolved] How to add an extra image to the header

  • I’m trying to modify the twentythirteen theme. What I want to do is to add an extra image just before the blog name.

    I try to modify header.php by replacing
    <h1 class=”site-title”><?php bloginfo( ‘name’ ); ?></h1>

    with:

    <h1 class=”site-title”><img src=”images/myextraimage.jpg”/><?php bloginfo( ‘name’ ); ?></h1>

    But somehow it seams that I get the wrong path to the image.
    So what path should I user?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Upload the image to your media library. Once it’s uploaded, go to its edit page. The “File URL” will display for you. Use that.

    Thanks, but that would make the image part of the data rather than the theme.

    I managed to solve it by using:

    <h1 class=”site-title”><img src=”<?php bloginfo(‘home’);?>/wp-content/themes/twentythirteen-child-01/images/myextraimage.jpg”/><?php bloginfo( ‘name’ ); ?></h1>

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘[Resolved] How to add an extra image to the header’ is closed to new replies.
Skip to toolbar