I’m not aware of any way to do this without editing code.
I wrote a PHP function which will wrap your post titles in a with the class “hastag-{tag-slug}”. You can put this in your theme’s functions.php file and then use the_title_with_tags() instead of the_title() in your theme templates.
function the_title_with_tags() {
//get all tags on this post
$tags = get_the_tags();
if ($tags) {
//store tag slugs in an array
$classlist = array();
foreach($tags as $tag) {
$classlist[] = 'hastag-'.$tag->slug;
}
//print the title with tags as CSS classes
the_title( '<span class="'. implode($classlist, ' ') .'">' , '</span>' );
}
else {
the_title();
}
}
And the you can add the styling rules to your CSS:
.hastag-football {
color: red;
}
.hastag-baseball {
color: yellow;
I think that’s cleaner than inline styling.