Hello.
I am trying to create a Javascript Autoclicker for my own use... that would do this:
After clicking on a button - it opens new tab/window and in this tab/window it redirects urls each 2 seconds...

But I am afraid I need to give up, cause I cant make my script redirect in the new window... This is how far I got:
Code:
<html>
<head>
<script type="text/javascript">
function open_win()
{
window.open('http://en.wikipedia.org/wiki/Main_Page','name');setTimeout("window.location = 'http://www.google.com/','name' ",3000);setTimeout("window.location = 'http://en.wikipedia.org/wiki/Portal:Contents' ",6000);setTimeout("window.location = 'http://en.wikipedia.org/wiki/Web_search_engine','name' ",9000);
}
</script>
</head>

<body>
<form>
<input type="button" value="Open 3 windows!" onclick="open_win()" />

</form>
</body>
</html>
But this script only opens one new tab and then redirects once on the main page, then the 3rd redirection fails because it is other page already - not the one with my java coding

ALSO: is there a way to tell the script which proxy it uses when loading new tab? Like order it to open nwe tab using different proxy - and keep redirecting within this proxy?


---------------
I also got the idea how to "redirect in new window"... but for that you need to manually click new tabs each time you want the new tab to reload different url... it is no good
Code:
<html>
<head>

<script type="text/javascript">

function open_win()
{
window.open('http://www.google.com/','stay');
}

function open_win2()
{
window.open('http://en.wikipedia.org/wiki/Main_Page','stay');
}



</script>
</head>

<body>
<form>
<input type="button" value="open google" onclick="open_win()" />
<input type="button" value="open " onclick="open_win2()" />

</form>
</body>
</html>

Any help?
Also - how to make that the "old tab" is focused after clicking the button? I mean - you click the button and stay in the same page, because now it automatically focuses on the new page.