Add a Floating Follow Me/US on Twitter Button To Your Website Easily



Most of the twitter users show their power by the number of followers they have. So its essential to get a good number of twitter followers if you want to become a power twitter user. Many websites out there put a small twitter icon, or a follow me on twitter statement near to their subscription button in their website to get followers. But actually these things go unnoticed for most of the visitors. So creating a floating Follow me/us on Twitter button in your website will surely grab viewers attention. (Each and Every visitor to your site will notice it for sure).
Add Twitter Follow ME button in WebsiteWhen i was looking for this i came across a website called Go2Web20 which gives the same. But it had many negatives. The most weird thing i found that it is based on JavaScript, so if a visitor with JavaScript disabled on his/her browser  visits the site then its of no use. Secondly it does not work on Internet Explorer (Still most of the people use IE). So i needed an alternative for this.

I found it easier to implement the same Twitter Follow floating button with the help of CSS. So, Here is a Simple way to

Add a Floating Twitter Follow Me/US Button to your website

The advantages of this method are :

It is compatible with all browsers.

It doesn’t use JavaScript at all.

Add this CSS code to your Website First.

#twitter-follow { border: 0;position: fixed;  top: 200px; right:0;}

(Blogger users should add this before ]]></b:skin> in your template)

In the above code top: 200px; the distance from the top you can adjust it to suit your website.

Now add the following code to your Website. (For blogger users add the code in your template just after the <body> tag)

<div id=”twitter-follow”> <a href=”http://twitter.com/amalroy”><img src=”http://img2.pict.com/91/e8/71/1279044/0/twitterfollowme.png” alt=”Follow Me on Twitter” /></a> </div>

Replace my name with yours. Also if you need the image to be shown on left side just replace right:0; in the css code with  left:0;

Add a Floating Twitter Follow Me or US Button to your website

You can replace “http://img2.pict.com/91/e8/71/1279044/0/twitterfollowme.png” with your own twitter Follow Me/US image if you want.

And here is the link for Twitter Follow US button.Add a Floating Twitter Follow Me or US Button to your website
http://img2.pict.com/ad/29/8b/1279120/0/twitterfollowme.png

You will now have a Twitter Follow Me button in your website similar to mine.

If you have any doubts regarding this comment it down.



Subscribe Now To Get Free Updates!!!  

Bookmark and Share

July 23, 2009 by Amal · 20 Comments 

Comments

20 Responses to “Add a Floating Follow Me/US on Twitter Button To Your Website Easily”
  1. Praz says:

    It is not working in Google Chrome and IE8. Working pretty well in Firefox and Opera. Amal can you say why? you can see my problem at http://www.clearglimpse.com

  2. Amal says:

    @Praz yes i saw you have problem with that twitter button in chrome and ie8. I suggest you to try the code given in above comment.

    Also add another set of same codes between these two tags.

    <!– [if lt IE 8]>

    <! [endif] –>

  3. Coolvibe says:

    Thanks, we just added it to our site (http://www.coolvibe.com).

    Note that you forgot to quote the URL in your code, remember the "" :)

  4. Amal says:

    @Cool Vibe

    Ah yes thanks for bringing it to my notice. Glad to see it on your site.

  5. uncople says:

    yo… love this thoughts.

  6. thanks !! very helpful post!

  7. Ian says:

    Hey I have read your articale and cant seem to get it to work any suggestions

    • Amal says:

      It works without any problems. I have tested it. The twitter button has problems only with internet explorer. Else it works perfectly. Do tell me your sites platform and name.

  8. CJ says:

    Hi,

    Great tutorial, just what I needed. Is there anyway to stop the badge overlapping left content though? So if you have the badge to the right and you drag the window left the badge will not overlap the main site content rather it would stop. This is mainly so that users with small resolutions don’t have site content obscured.

  9. Lynn says:

    This is working for me except that in IE it is in the top corner, it is showing in the correct position in Firefox and Safari. Help.

    • Amal says:

      It has certain compatibility issues with internet explorer. But try inserting the code once more between these two tags.

      along with the other codes.

  10. xymantec says:

    Ok so I noticed a bit of misinformation and a bunch of thanks, nothing really there to help people solve the IE8 problems with this syntax so here I go!

    In MOZ or Chrome this code seems to work fine:

    #twitter-follow {
    border: 0;
    position: fixed;
    top: 123px;
    right:0px;
    }

    With IE we experience the Microsoft effect (don’t wanna cooperate)
    Depending on the application of this feature you might wanna check out other methods. But if just want something simple that should work then this should do it for you.


    #twitter-follow {
    border: 0;
    position: fixed;
    padding-top: 108px;
    margin-right:-10px;
    float:right;
    }

    IE seems to be a little stupid with positioning so using a float will produce the same result, as you can see I had to subtract some of the margin on the right side of the image.

    Note: if you are using multiple ’s you might want to apply a z-index property so that when the page is being viewed by a smaller screen (like a netbook) it does not distort your site design, as I have experienced.


    #twitter-follow {
    border: 0;
    position: fixed;
    padding-top: 108px;
    margin-right:-10px;
    float:right;
    z-index:-1; /* <<– z-index property */
    }

    Remember all designs are diffrent so this may have to be adjusted according to the application type.

    hope this helps, enjoy!

  11. method77 says:

    those who copied the code and doesn’t work, remove the quote marks and replace them with new ones

Speak Your Mind

Tell us what you're thinking...
and oh, if you want a pic to show with your comment, go get a gravatar!

CommentLuv Enabled