Wilkie Martin - Surviving Publication

Author of the unhuman series of addictive comedy cozy mysteries set in the Cotswolds. This documents my encounters with publishing and includes things I hope will be useful later. It also covers some local writing competitions and reviews some writing events.

Monday, 15 March 2010

Adding a different 'tweet me' button to blog

In my last posting I wrote how we'd just added a 'tweet me' button to my blog. However, as we are getting some errors returned we have now swapped for a different button using tweetmeme.com.

See http://bloggerstop.net/2009/04/tweet-it-and-retweet-buttons-for.html for the instructions.

Or follow the steps we took (and using some of the code from there):

  • In blogger.com.
  • In 'layout' .
  • In 'edit html' .
  • Download a copy of the template first.
  • Tick 'expand widget code' (on the right hand side just above the code box).
  • Find this code (towards the bottom)

    <div class='post-footer-line post-footer-line-1'>
  • Add the following code:

    <b:if cond='data:blog.pageType == &quot;item&quot;'>
    <script type='text/javascript'>tweetmeme_url = ' <data:post.url/>';
    <script src='http://tweetmeme.com/i/scripts/button.js' type='text/javascript'>
    <b:if cond='data:blog.url == data:blog.homepageUrl'>
    <script type='text/javascript'>tweetmeme_url = '<data:post.url/>';
    <script src='http://tweetmeme.com/i/scripts/button.js' type='text/javascript'>
  • This puts the 'tweet me' button after each posting and after posting on the home page, but not on the additional pages.
  • Preview, and if all ok, save the template.

My Related Postings

Losing twitter and adding a 'tweet this' button to blog
Linking twitter to facebook and adding twitter to blog
How to add additional pages in #blogger

No comments:

Post a Comment