(Reading time: 3 – 4 minutes)
The WordPress Journalist is an excellent theme for anyone wanting to use a blog to deliver a lot of information with a minimum amount of fuss.Part of what makes Journalist such a good theme is that it’s easy for WordPress beginners to modify in simple, powerful ways. For example, moving the author’s byline from below the post to above the post is very simple.
But the default author styling is too plain. Let’s add a little punch to it using a bold font, as shown in the screenshot above.
WARNING: Make a fresh backup before poking around in theme files.
Add font format class to style.css
We’ll need to either 1. find an existing class in the Journalist style sheet, or 2. create a new, custom CSS class just for ourselves. I’m going to save you some time here… I poked around in the Journalism style.css file, and I didn’t find anything useful for simple author byline formatting.Since we want to restyle the author’s byline, let’s make it really easy and create a CSS class called “theauthor.” Here’s how:
- Click on “Appearance >> Editor” in your sidebar menu. This will open in the style.css file.
- Scroll to the bottom of style.css
- Add this formatting, also shown in the screenshot:
1 2 3
span.theauthor { font-weight: bold; }
That was easy! Now, we need to add the styling information to each page template in the theme.
Add class to page templates
As noted in “Moving The Author’s Byline In WordPress Journalist Theme,” 5 files need to be modified: archive.php, single.php, index.php, search.php and page.php. Below is a screenshot of what this looks like in your theme editor:
As you can see, it’s pretty easy. Just wrap the_author() tag with the span, here’s what the code looks like:
1 | <span class="theauthor"><?php the_author() ?></span> |
Again, easy business. Make sure to add the span to all 5 files, and check to make sure everything works. If you make a mistake, it will break your website, and you will notice. So will everyone else. It’s not hard, just take care. This is why you did a backup before you started, right?
Is there more you want to do with the author information? There’s more I’m going to do. Stay tuned.




Nice post!
Thanks!
Hey,
Great post! I’m using the journalist theme and am trying to find out how to change the ‘without comments’ that appears underneath my post title if no one has made a comment on my blog?
Cheers,
Andrew
@Andrew – this isn’t too difficult. I’ll see about getting a post up about it within a day or two.
.-= Dr WordPress!´s last blog ..Startup Weekend Women 2.0 August 28, 2009: Proposal =-.
@Andrew –
I don’t have to write this up at the moment.
However, it’s pretty easy. Poke around in the index.php and the page.php files, and you will see what you need to do.
Make a copy of your theme before you go breaking stuff.