The title of this post is an oft repeated question I receive in my emails and in the comment section of this site. “How to change my site name to a logo?”. For someone with few basic skills in html and css , this wont be a big deal. But I am hoping this will help those who want to do this but unable to figure it out. This also works out easy for me , so that I wont have to reply to those mails separately. I have created a screencast which will show you the entire process. However I am going to write down the steps involved.
1. Create and save your logo image to the images directory of your template. In this case we name it as logo.png
2. Open the header.php file of the template and find the section where your site name is given. It often looks like given below.
<h1><a href="<?php bloginfo('siteurl');?>/" title="<?php bloginfo('name');?>"> <?php bloginfo('name');?> </a></h1>
3. Change it to the following.
<h1><a href="<?php bloginfo('siteurl');?>/" title="<?php bloginfo('name');?>"> <img src="<?php bloginfo('stylesheet_directory');?>/images/logo.png"/> </a></h1>
Watch the screencast