Skip to content

Instantly share code, notes, and snippets.

@perryn
Created September 11, 2012 10:56
Show Gist options
  • Select an option

  • Save perryn/3697583 to your computer and use it in GitHub Desktop.

Select an option

Save perryn/3697583 to your computer and use it in GitHub Desktop.
twitter.html
<!DOCTYPE html>
<html lang="en">
<body>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.5/jquery.min.js"></script>
<script>
$(document).ready(function(){
twitter_ids = [
"perrynfowler",
"matthewcashmore",
];
var items = [];
$.each(twitter_ids, function(index, id) {
$.getJSON('http://api.twitter.com/1/users/lookup.json?screen_name=' + id, function(data) {
$('<div/>', {
html: id + ',' + data[0]['followers_count']
}).appendTo('body');
});
});
});
</script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment