daveWare 0 Posted September 11, 2008 Report Share Posted September 11, 2008 Hello,I'm trying to run a js that will open a child window, or if the window is already open, change the focus to that window. Here is the script: //use this one in Shoppingfunction openDes() { if (window.opener && !window.opener.closed) { // if the opener is closed window.opener.focus(); // change the focus to the opener: does not work in tabs: domainsecurity issue (?) } else { window.open('http://designer.kaneva.com/', 'designer'); // open designer in a new window } } the script works perfect if the pages are open in 2 different windows. However if the pages are open in tabs i can't change focus or even close one of the pages. the pages are sitting in 2 sub domains:http://shop.kaneva.com/andhttp://designer.kaneva.com/is there a way to change the focus to the opener when tabs are being used? Thank you,Dave Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.