15 August 2011

How to add authorship markup for Blogger

One of the recent features added to search is the ability to display author information in search results, specifically a picture and a link to the Google Profile. It’s another move that should improve the quality of search results, by adding a layer of trust and limiting the spread of scrapping and content farms. In the couple of months since the launch, the process has been revised and simplified and there are several methods available, as described in the Webmaster help documentation.

The easiest way to add authorship markup to your blog or site, provided you have a Google account, is to add a button with the code provided here. In , for example, you can put that code in a HTML gadget and add it to the sidebar. To verify that you really are the person behind the Google profile you are linking to, make sure the profile also contains a link to your blog, otherwise the markup will not work. It’s a simple security measure to prevent people linking their own pages to popular authors, trying to rank better is search results.

Naturally, I also wanted to get in on the action. My solution is a little more complicated, as it requires some changes to the Blogger template. I like it better, because it works without an extra button on the page – not every design works together with the Google button – and also without setting up an author profile page (just laziness, I guess). The idea is to add the link pointing to the Google Profile to the field with your Blogger author name – the ‘Written by…’ section under the article title – and have it show up only on articles, not on archive of label pages.

As usual, go to the ‘Design’ section in the Blogger dashboard, switch to the ‘Edit HTML’ tab and check ‘Expand widget templates’. Or, if you prefer the new look of Blogger in Draft (I don’t), click ‘Template’ in the sidebar to the right, scroll all the way down, expand the section ‘Edit Template HTML’ and check ‘Expand widget templates’. Search for the section that starts with the following code line (the start of the author section in the blog post):

<span class='post-author vcard'>

and ends with (the date/time of the article):

</span> <span class='post-timestamp'>

Replace the code in between with the one listed below, so that the final result looks like in the example, and then save the template. The bold text represents the new code and you should adapt the italic text by changing the link and title to point at your own Google Profile. This works only if the blog has a single author; for multiple authors the code would be more complicated, with an additional if/else block testing for the author and inserting a different link for each of them.

<span class='post-author vcard'>
<b:if cond='data:top.showAuthor'>
<data:top.authorLabel/>
<b:if cond='data:blog.pageType == &quot;item&quot;'>
<a href='https://profiles.google.com/george.moga' rel='author' target='_blank' title='George Moga'><data:post.author/></a>
<b:else/>
<span><data:post.author/></span>
</b:if>
</b:if>
</span> <span class='post-timestamp'>

There is one last step involved, regardless of the method you choose, probably the most important one: submitting your work to Google through this form. It also requires a great deal of patience, because the verification is not done rapidly; in my case I added the code and submitted the form about a month ago. After that check back the Rich Snippets Testing Tool from time to time; the messages there will alert you when the markup is verified or if there are any errors. My guess is that there is some kind of manual filtering involved, that there are actual people checking your content to insure it’s at least original, before they give the final go-ahead for the site. As the warning here states, even if the markup is verified, there is no guarantee your picture will show up in search results; in my case it doesn’t right now, but maybe sometime in the future…  Authorship markup in Blogger - the result

10 comments:

  1. I just do not think this is worth the trouble.
    I was reading it was supposed to help traffic greatly.

    ReplyDelete
    Replies
    1. While I don't have any data whether it helps traffic or not (it would be an interesting idea to check for it though) it's not that much trouble. In the mean time these steps are not really necessary, you can simply choose to link your Blogger profile to your Google+ profile and the authorship markup will be handled automatically by Blogger.

      Delete
  2. Hello,

    Thanks, I have implemented on my own blog, www.examsexpert.in and thanks for the tips.

    ReplyDelete
  3. Many Thanks!! in other blogs talk about put some "me" and "author" tags but this is so simple, and passed the test in Google´s Rich Snippet Tools for my blog urudetodo.blogspot.com, now i will wait a few weeks right?Thanks a lot!!!! Diego From Uruguay

    PS: Sorry for my bad English

    ReplyDelete
    Replies
    1. Yeah, it can take some time until it's live; in my case I think it was longer than a month.

      Delete
  4. Thanks !
    I've added rel=author to my google+ profile in my blog.

    ReplyDelete
  5. I did it on my blog but it doesn't view as a link in results. Just "by Suvin M.V". It is not shown as a link. Search in google "blogurl:friwiz.blogspot.com" Please help.

    ReplyDelete
    Replies
    1. The change is not reflected immediately in Google Search results. Did you check with the Rich Snippets Testing Tool if everything is set up OK?

      Delete
  6. Salut George.

    Recurg la limba pe care o stapanesc cel mai bine ptr ca altfel mi-e greu sa explic. Ma chinui de zile bune sa scap de doua erori din google structured data:
    Eroare: Missing required field "updated".
    Eroare: Missing required hCard "author"
    Am gasit articolul tau, insa codul din template-ul meu e un pic diferit


    span class='post-author vcard'
    b:if cond='data:top.showAuthor'
    b:if cond='data:post.authorProfileUrl'
    span class='fn'
    a expr:href='data:post.authorProfileUrl' itemprop='author' rel='author' title='author profile'
    data:post.author
    /a
    /span
    b:else/
    span class='fn'>/span

    /b:if
    /span

    Se poate sa compilez codul tau in ceea ce am eu in template?

    ReplyDelete
    Replies
    1. Articolul meu e destul de vechi, în momentul de față Blogger e mai bine integrat cu Google+, așa că din câte știu e suficient să legi contul Blogger cu cel de Google+ și partea de authorship markup se va rezolva automat. Poți folosi și codul meu în orice caz, cu link la profilul tău de Google+.
      Cât despre erorile de mai sus, le am și eu în continuare, chiar dacă profilul meu a fost legat de blog și apare în rezultatele de căutare. E ceva ce ar trebui probabil corectat de echipa Blogger, dar personal am ales să le ignor, nu par să afecteze în nici un fel integrarea cu authorship markup.

      Delete