Legendary. Was working on building this exact kindof thing but you beat me to it. Took 1.5 minutes and it worked.
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.