Skip to content

Instantly share code, notes, and snippets.

@martindale
Created August 18, 2014 21:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save martindale/282be6ef94c7533dbf7c to your computer and use it in GitHub Desktop.
Save martindale/282be6ef94c7533dbf7c to your computer and use it in GitHub Desktop.
extract an array of tracks from a Google Music playlist table
var playlist = $('table tr.song-row');
var tracks = [];
playlist.each(function(i , row) {
var $track = $( row );
var title = $( $track.children()[0] ).text();
var artist = $( $track.children()[2] ).text();
tracks.push( artist + ' – ' + title );
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment