This little snippet will retrieve the number of twitter followers you have and show it on your page, and can be used in every application.

function countFollowers($username){
$url = “http://twitter.com/users/show/{$username}.xml”;
$content = simplexml_load_file($url);
return “Followers: {$content->followers_count}”;
}
echo countFollowers(“scriptplazza”);
 

Leave a Comment