Replacing an image logo by text in WordPress

Some themes in WordPress (like this one) only allow an image logo in place of a title.

Here is a quick way to replace that image by a text title using jQuery:

1- Install the WP-Headmaster plugin.

This is a great way to allow more control over the header of pages in your WordPress site, including injection of jQuery code.

2- In WP-Headmaster settings, under the ‘scripts’ tab, set the first option to No influence and copy this code in the script text area:

jQuery( document ).ready(function() {
 jQuery( 'img#logo' ).hide().after( "<span style='font-size: x-large; font-weight: bold;
display:inline; padding-left:10px;'> My Title </span>" );
});

Note that the identifier for the logo to replace can change from theme to theme.

Leave a Reply

Your email address will not be published. Required fields are marked *

%d bloggers like this: