In recent months Twitter has begun to change their API and how sites interact with their services. As a result, Twitter @Anywhere applications are being eliminated from their product offerings. In the near future, these specific types of applications are being replaced by newer arrangements rendering this information obsolete.
I began experimentation with Twitter comments on this blog some months ago. Initially I utilized the @Anywhere tweet box provided by Twitter's developers. Although this functioned, I found the implementation unreliable due a problem with the iFrame Twitter uses. Since I had it hidden by default, sometimes the page loaded properly and others it didn't. Despite some reader enthusiasm for a tutorial I held off until I could present a better working implementation and I think I'm finally there.
In a multi-part series I'll illustrate how to integrate my custom Twitter comments into your blog. Let's begin by registering an @Anywhere application with Twitter. This is required to securely authenticate visitors to Twitter so they may tweet and perform other actions directly from your blog. It's a fairly simple task, but I'd like to cover a few items in detail hence multiple parts.
Registering an @Anywhere Twitter ApplicationLog in to Twitter and visit the New Twitter App form. Here you'll find the form below, which I've filled in using this blog's application as an example. Complete this form using information appropriate to your blog. Note: be certain to use your Blog URL for the Callback URL otherwise many features will not work.
<script src="http://platform.twitter.com/anywhere.js?id=YOUR_API_KEY&v=1"/>You've now enabled your blog for @Anywhere so a visitor may authenticate to Twitter allowing your application to carry out common tasks. With enough programming know how one can even write a fully functional Twitter client using this technology. However, for now we'll only worry about the basics.
Advanced Topic: Using a single Application for multiple SitesTwitter includes a wonderfully useful feature to authorize several domains to use a single Applications credentials. So, if you operate blogs on several different topics it's quite easy to integrate these changes into each one without the need to create specialized applications for each, although in some cases you may prefer new apps. For now, let's consider the possibilities.
Suppose for a moment you've created a personal blog, another to share thoughts on books you're reading, another showcasing the local music scene and one for your flourishing small business . Each has its own niche readers, but the business blog audience doesn't mesh well with the more personal nature of the others. In this example, rather than creating a new app for each blog there's some comfortable overlap that allows the more personal blogs to work under a single branding, namely yourself. So, you setup an app branded on your name so readers know who's app they're using and it's time to give each access.
To setup multiple sites to use a single App visit Twitter Developers, visit My Applications then click on your Apps name and select the @Anywhere Domains tab. Here you may add blog URLs to your applications authorized list. I've noticed it takes at times a few minutes to take effect, but once added this new domain may use the same API Key as another. This cuts down on duplication and makes it that much easier to use @Anywhere features on several sites. I highly recommend it when appropriate.