views:

28

answers:

1

Ok, i won't go into the full details (too much to explain) but here is what i am trying to do. I have a button on a webpage (we'll call page-1) that links to a page (we'll call it page-2). This page opens in the same window. However, i need the page (page-2) that opens to open up a new window with another page (we'll call this one page-3) when it loads. So virtually when you click the initial button (on page-1) it will go to a new page (page-2) AND a window will open as well with a different page (page-3).

This is where it gets tricky. I need page-2 to automatically redirect back to page-1 after it launches page-3. Is this possible and if so, how?? Could it be a JQuery thing?

Please just give some answers...i know this is way crazy and a huge workaround - but this is my last resort for this particular website. I have to do it this way because of the lack of control over some of the code.

+3  A: 

What about this doesn't solve the problem?

page2.html:

<html>
  <head>
  <script type="text/javascript">
  $(document).ready(function () {
    // Open a new window, displaying page3
    window.open('page3.html');

    // Redirect the current window to page1
    window.location('page1.html');
  });
  </script>
</head>
...
meagar