Create a gist now

Instantly share code, notes, and snippets.

Top hotttest Twitter artists
<!DOCTYPE html>
<title>Top Twitter</title>
<script type="text/javascript" src=""></script>
<link type="text/css" href="styles.css" rel="stylesheet" />
<h1 id='title'> Top 100 artists with verified Twitter accounts</h1>
<ol id="results"> </ol>
<div id="footer"> Powered by <a href="http:/">The Echo nest </a></div>
<script type="text/javascript">
function fetchTopTwitterArtists() {
var url = '';
$.getJSON(url, { 'api_key': 'N6E4NIOVYMTHNDM8J', 'format':'jsonp',
'results': 100, 'bucket': ['hotttnesss', 'id:twitter'], 'limit': true}, function(data) {
for (var i = 0; i < data.response.artists.length; i++) {
var artist = data.response.artists[i];
var elem = $("<li>");
var link = $("<a>");
var handle = artist.foreign_ids[0].foreign_id.replace('twitter:artist:', '');
link.attr('href', '' + handle);
$(document).ready(function() {
jQuery.ajaxSettings.traditional = true;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment