Eric Nagel

Rel Author Markup for Thesis

I have been, or can be if you click on a link and make a purchase, compensated via a cash payment, gift, or something else of value for writing this post. Regardless, I only recommend products or services I use personally and believe will be good for my readers.

Inspired by a Tweet by Tom Critchlow

Ok, time for me to feel smug. Managed to get rel author markup working and appearing in SERPs for my tumblr site:http://t.co/6jsVAwJ

I decided to attempt to do the same thing with my own blog (EricNagel.com), which runs on Thesis.

The first step was adding my Google Plus profile URL to my Profile (/wp-admin/profile.php) in the Website field. It’s important to add ?rel=author to the end of your profile URL, so mine is

https://plus.google.com/111702920195070669389?rel=author

Next, I’m going to edit

/wp-content/themes/thesis_18/lib/custom/custom_functions.php

and add:

function custom_get_the_author_link() {
	return get_the_author_meta('user_url') . "\" rel=\"author";
}
add_filter('author_link', 'custom_get_the_author_link');

Upload this file after you’ve made the changes. It’s a little ugly, but that’s the only way I could trick thesis into adding the proper “rel” property to the href.

Next, make sure none of your links (/wp-admin/link-manager.php) have the Relationship author. If so, edit those links and uncheck the Identity box, another web address of mine.

The last step of changes: go to your Thesis Design Options page, and under Bylines, check Show author name in post byline and Link author names to archives. Do not check Add nofollow to author links.

Finally, it’s time to test out the changes.

The first step in testing is to go to your site and make sure it looks good. You should see your name under a blog post’s headline, and it should be linked to your Google Plus profile.

Visual test

Next, using Google’s Rich Snippets Testing Tool, enter an individual post’s URL, and click the Preview button. You should see your Google Profile picture next to the search result.

Google Snippet Preview

(Note: my blog also has breadcrumbs marked-up, so you’ll see that in my preview, too.)

Now we play the waiting game. Google has to re-visit these pages to see the change, but you should see the results shortly!