Instagram Like (heart) auto click Post Bookmarklet
Objective: Click all "Like" heart on page http://www.gramfeed.com/instagram/tags#photo
Here is the code I was working with. This one worked on another site,
var a = document.getElementsByTagName('a'); var b = []; for(var i=0, len = a.length; i < len; i++){ if(a[i].id.indexOf('like') !== -1){b.push(a[i]) } }; for(var i=0, len = b.length; i < len; i++){ b[i].click() };
The following should work; I've tested it on my end, and it likes the hearts(though that doesn't work since I'm not logged in, etc).
As to the class checking 'function', credit where credit is due in regards to this answer.
Update
I am still unsure if the above code will really work, but it has so far 'worked' in jsfiddle(drag link to button bar, click link in button bar, observe console).