How to add Twitter @Anywhere Hovercard in WordPress

How to add Twitter Anywhere Hovercard in WordPressRecently, I got an email from a user asking: How to implement twitter @Anywhere Hovercard in WordPress. Adding @anywhere is relatively an easy process. You can either add the twitter anywhere hovercard manually or install a plugin.

Twitter Anywhere helps to get more traffic, more tweets and more engagement. It can convert the twitter username to links (like – @wpkube) and adds a lot more options.With hovercard option, users can see a hover box with a follow button & user information.

In this post I’m going to walk you through a step by step tutorial on how to add hovercard to WordPress.

Step 1: Create an Anywhere application »

The first step is to create an twitter anywhere application. On registration an anywhere application page, you have to fill-in all the details for Application Name, Description, Website etc.

Twitter hovercard application

Step 2: Add the following code »

Once you complete the registration process, copy and paste the following code to your header.php file (before </head)

&lt;script src=&quot;http://platform.twitter.com/anywhere.js?id=APIKey&amp;v=1&quot; type=&quot;text/javascript&quot;&gt;&lt;/script&gt;
&lt;script type=&quot;text/javascript&quot;&gt;
twttr.anywhere(onAnywhereLoad);
function onAnywhereLoad(twitter) {
twitter.linkifyUsers();
};
&lt;/script&gt;

Make sure to paste your own consumer or API key where it says APIKey in the link.

For Thesis Theme Users

If you’re using thesis theme framework, then paste the code in “Additional Scripts” Section. Go to > Thesis > Site Options > Additional Scripts.

twitter site options

Now every time you will link to a twitter account @wpkube, it will be automatically linked to the appropriate twitter profile.

About the Author: Devesh Sharma is a WordPress fanatic and loves experimenting with WordPress themes & plugins. Get more from Devesh on  and Twitter.

You May Also Like:

2 comments… add one
  1. Thanks for explaining this one – will be checking it out Devesh.

Speak Your Mind...

A Weekly WordPress Newsletter...

Subscribe now and you will get -

»  Free Guide – Building a Successful WordPress Blog.
»  Weekly Newsletter curating useful blog posts and resources.
»  Exclusive Discount & Deals on Premium Products.

Your email will never be shared with anyone.