Skip to content

Instantly share code, notes, and snippets.

@nderscore
Last active December 18, 2015 07:19
Show Gist options
  • Save nderscore/5746261 to your computer and use it in GitHub Desktop.
Save nderscore/5746261 to your computer and use it in GitHub Desktop.
Bookmarklet. Displays all available metadata for the currently playing track on turntable.fm. Track tags are output to the chat area and only visible to you.
javascript:(function(){for(var x in turntable){if(turntable[x]!=null&&turntable[x].hasOwnProperty('numDjs')){var s=turntable[x].currentSong.metadata,e=document.createElement("div");e.className="message";e.innerHTML="<b>Artist:</b> "+s.artist+"<br /><b>Album:</b> "+s.album+"<br /><b>Song:</b> "+s.song+"<br /><b>Genre:</b> "+s.genre+"<br /><b>Length:</b> "+Math.floor(s.length/60)+"m"+(s.length%60)+"s";var m=document.getElementsByClassName("messages")[0];m.appendChild(e);m.scrollTop+=999;}}})();
/* _nderscore/turntable.fm */
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment