Skip to content

Instantly share code, notes, and snippets.

@brianhenk
Created November 18, 2011 01:12
Show Gist options
  • Save brianhenk/1375202 to your computer and use it in GitHub Desktop.
Save brianhenk/1375202 to your computer and use it in GitHub Desktop.
Highlights florence + the machine scrobbles from last.fm so they can easily be deleted
var allRows = document.querySelectorAll('table.tracklist tr');
for(var i = 0; i < allRows.length; i++) {
var artist = allRows[i].querySelector('td.subjectCell a').innerText;
if(artist == 'Florence + The Machine' || artist == 'Florence & The Machine') {
var deleteButton = allRows[i].querySelector('td.deleteCell a.delete');
deleteButton.setAttribute('style', 'left: 0px;');
} else {
allRows[i].setAttribute('style', 'display: none;');
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment