WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] logo instead of site title (8 posts)

  1. webwitch
    Member
    Posted 3 years ago #

    I have been trying to tweak the site title code in the header to include a logo instead of the site name in text. I looked at a similar post to replace both the title and description which govpatel answered.

    But I just want to add a logo and keep the home link etc. I have tried a few tweaks with the code below but don't seem to insert the img src code in the right place.

    " title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>" rel="home"><?php bloginfo( 'name' ); ?>

    Any ideas please?

  2. Joseph
    Member
    Posted 3 years ago #

    Did you try replace <?php bloginfo( 'name' ); ?> with your <img> tag?

  3. webwitch
    Member
    Posted 3 years ago #

    Just tried it and it works! Thank you! I had been trying some complicated code concoctions but this is really simple.

    Great stuff!

  4. Joseph
    Member
    Posted 3 years ago #

    You're welcome.

  5. tony matts
    Member
    Posted 3 years ago #

    I am trying it but the image does not show, and I only get a black line. The image is "there" but not showing.

    <span>
    " title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>" rel="home"><img src="images/headers/made.png" width="163" height="26" alt="" border="0">
    </span>

  6. tony matts
    Member
    Posted 3 years ago #

    Hey, moving along.

    Resolved a different way.

  7. webwitch
    Member
    Posted 3 years ago #

    Make sure you use the full URL for your image location otherwise it won't work ie. <img src="http://www.yourdomain.com/wp-content/themes/twentyten/images etc"

  8. Louis
    Member
    Posted 2 years ago #

    Does anyone know how to get rid of the black lines above and below the header/title logo after putting it?

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags