Official Twitter Follow Button for Blogger

Twitter has officially launched their Follow Button, which can be also added to Blogger. The best feature of this Follow button is that your readers don't need to visit Twitter to find and follow you. Instead, with just one click, they can instantly follow you without leaving your blog.

Twitter Follow Button for BloggerIt can also show the number of followers you have and can also be customized according to your needs. You can always visit Twitter official page to get the Follow Button but having it for Blogger posts requires a series of simple steps which I will guide you through.

Adding Twitter Follow Button to Blogger

Step 1: Login to Blogger, go to Template tab and click “Edit HTML”.

Step 2: Find </body> and before it add the following script:

<script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0];if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src="//platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");</script>

Remember, if you have added this Twitter JavaScript API previously, like, while adding the Tweet button, then you don’t need to add this script again.

Step 3: Save your template.

Step 4: Now go to Layout tab and add a “HTML/JavaScript” gadget to your sidebar or wherever you want.

Step 5: Use the below code generator to get your Twitter Follow button.

Button options

Type your Username:

Show Username:

Show followers count:

Button size:

Preview and code

Ajax Loading
<a href="https://twitter.com/blogger_raju" class="twitter-follow-button" data-show-screen-name="true" data-show-count="true" data-size="true">Follow @blogger_Raju</a>

Step 6: Copy and paste the above code to the “HTML/JavaScript” gadget (as mentioned in step 4) and save it.

Attributions

  • Username - The default is set to blogger_raju (that is me). Change it to your Twitter username.
  • data-show-count - show the number of followers; ‘true’ (to show the count) and ‘false’ (not to show the count).
  • data-show-screen-name - show your @username. The default value is ‘true’. Use ‘false’ to disable it.
  • data-size - controlling the size of the Twitter Follow button. When not mentioned, it shows the medium/normal size. To make it large use ‘large’.

This post has been updated on July, 2012.

Popular posts from this blog

Add Google Web Fonts to Blogger

How to Add Extra Gadget/Widget Section to Blogger Header

Add Open Graph Protocol Meta Tags to Blogger