ThemeShaper Forums » Thematic

[closed]

2 Color Blog Title

(4 posts)
  • Started 2 years ago by whitworthw
  • Latest reply from helgatheviking
  • This topic is not resolved
  1. whitworthw
    Member

    Hi all,
    If the title for my blog is "BlogTitle" (one word) and I want "Blog" to be green and "Title" to be red, how would I go about doing this? With HTML I'd just add a span class, but being a PHP noob I have no idea.

    Thanks,
    William

    Posted 2 years ago #
  2. i used this on a site, which just wraps certain parts of my title in spans:

    function childtheme_override_blogtitle() {
    	$t = get_bloginfo('name');
    	$t = str_replace('for','<span class="for">for</span>',$t);
    	$t = str_replace('Weight Training','<span class="weight">Weight Training</span>',$t);
    	$t = str_replace('Women Today','<span class="women">Women Today</span>',$t);
    
    	if (is_home()) { ?>
    	   <h1 id="blog-title"  class="clearfix"><a href="<?php bloginfo('url') ?>/" title="<?php bloginfo('name') ?>" rel="home"><?php echo $t; ?></a></h1>
    	 <?php } else { ?>
    	     <h3 id="blog-title"  class="clearfix"><a href="<?php bloginfo('url') ?>/" title="<?php bloginfo('name') ?>" rel="home"><?php echo $t; ?></a></h1>
    	<?php }
    }
    Posted 2 years ago #
  3. This is pretty cool: http://letteringjs.com/

    Posted 2 years ago #
  4. me like.

    Posted 2 years ago #

RSS feed for this topic

Topic Closed

This topic has been closed to new replies.