Connect with us

Development

Add Tweet button with Tweets Count in Your Blog Posts

Published

on

Twitter Share Submit Button for Blogger BlogWhen it comes to sharing something quickly to the world, Twitter comes in mind immediately. Its one of top places over internet where people share anything they want in just few clicks.

If you want your blog’s articles to be shared and viewed instantly by world, you can install a quick tweet button in your blog that helps your readers in tweeting your articles.

I’ve shared a “Twitter-Submit Button for Blogger Blog” before. But the little disadvantage of that button is that it just tweets the article but doesn’t show the number of tweets that articles has received.

Tweetmeme offers a tweet button that not only tweets but also show the number of tweets the article has received on the same submit button.

If you want to add this button to your blog, follow these simple steps below:

1. Go to your blogger’s Layout >Edit HTML page.

Advertisement

2. Check “Expand Widget Templates”.

3. Search (Ctrl+F) for :

 

Note: If you’re using “Expandable post summaries“, you’ll find the above tag twice. In that case consider the first one you find in your template.

4. And Just ABOVE this paste this code:

Advertisement

Replace “YOUR-TWITTER-USERNAME” with your twitter username. (without @)

5. Hit Preview and see the changes. And then Save if the button is there in top right of every post.

COMPACT BUTTON

If you want a compact version of the button, use this code in step 4





Replace “YOUR-TWITTER-USERNAME” with your twitter username. (without @)

Advertisement

That’s it.

Now press this button to see how it works 🙂

PING YOUR BLOG

If tweet count is not increasing in any of your posts, or a ‘?’ is displayed in the button, you can ping your blog from tweetmeme.

Update: Issue with Blogs without Post Summaries

The wordpress version of tweetmeme plugin works fine and shows correct tweet counts on all posts. I searched for and found that if you’re on blogger and not using expandable post summaries then you’ll face a issue of tweet button showing invalid tweet counts or same counts for all posts on home page.

To resolve this, we have to remove the tweet button from home page and show it inside posts by explicitly putting post summaries hack:

Advertisement

1. Search for

 

in your template.

2. and just BELOW it paste this code:

Advertisement

— PLACE TWEET BUTTON’s CODE HERE —

 

 

 

3. replace — PLACE TWEET BUTTON’s CODE HERE —
with the button’s actual code.

Advertisement
Advertisement
Comments