7 points · by amima · 14y ago · 4 comments
setInterval( function() { var buttons = document.getElementsByClassName( 'buy-button-price' ); for ( var i = 0; i < buttons.length; i++ ) { if ( buttons[i].value === 'Proceed' ) { buttons[i].click(); console.log("click") } } }, 4000);
However, it HAS NO DETECTION OF SUCCESS, there is a popup not a page change. If I did it again I'd save the setInterval() result id and then use clearInterval(thatVar) when it works.