Skip to content

Instantly share code, notes, and snippets.

@jonocairns
Last active March 6, 2016 01:13
Show Gist options
  • Save jonocairns/dda9d93d0859bb19696b to your computer and use it in GitHub Desktop.
Save jonocairns/dda9d93d0859bb19696b to your computer and use it in GitHub Desktop.
var totalLength = $('tbody td form[rel=\'0\']').length;
for(var i = 1; i < totalLength; i++){
console.log('click: ' + i);$('tbody tr:nth-child(' + i +') form[rel=\'0\'] input[type=submit]').click();
pause(300);
}
function pause(milliseconds) {
var dt = new Date();
while ((new Date()) - dt <= milliseconds) { /* Do nothing */ }
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment