2 Jun 2011

Add +1 buttons to your blog manually

Want +1 button on your Blogger blog, but you don’t want the full share widget?  Here’s how you can manually add only the +1 button to your blog:
  • Configure your +1 button and get the code from Google.
  • Remove href attribute of <g:plusone> starting tag; insert expr:href='data:post.canonicalUrl' in its place.  For example, the code on my blog is: <g:plusone expr:href="data:post.canonicalUrl" size="medium"/>
  • Insert the code in your blog’s template.
    • Open Blogger > your blog > Design > Edit HTML.
    • Check “Expand Widget Templates”.
    • Look for <div class="post-footer">
      if you want to place the +1 button at the bottom of each post; look for <div class="post-header"> if you want it at the top of each post.
    • Paste the +1 button’s code.  View your blog to see if the button appears at the right place, and adjust the placing accordingly.
Leave a comment if you have any questions.

No comments:

Post a Comment