title: Opening a new window/ document in PhoneGap
body: <p>With the following code, I am able to open a new window on a Desktop browser:</p>
  
  <pre><code>            var thisWin = window;
              var oauthWin = thisWin.open(data, 'twitter-oauth-window', 'location=0,status=0,width=800,height=400');
              var lastUrl = oauthWin.location.href;
              var meh = true;
              var oauthInt = thisWin.setInterval(
                function()
                {
                  if (meh)
                  {
                    alert(
                      '\noauthWin.closed: ' + oauthWin.closed +
                      '\noauthWin.location: ' + oauthWin.location +
                      '\nthisWin.closed: ' + thisWin.closed +
                      '\nthisWin.location: ' + thisWin.location +
                      '\noauthWin===thisWin: ' + (oauthWin === thisWin));
                    meh = false;
                  }
                  // do more stuff here
                }
              );
  </code></pre>
  
  <p>In the debug output within the alert:</p>
  
  <pre><code> oauthWin===thisWin: false
  </code></pre>
  
  <p>Which is what it should be. However, when the same code is run within PhoneGap, I get the following:</p>
  
  <pre><code> oauthWin===thisWin: true
  </code></pre>
  
  <p>Which indicates that PhoneGap has opened the new URL in the same window, replacing the current HTML document.</p>
  
  <p>I wish to open the new URL separately, and to be able to close it upon a certain condition being met, and revert to the old one.</p>
  
  <p>Can this be achieved in PhoneGap, and how?</p>
  
  <p>Thanks!</p>