javascript - Oauth login popup not closing in ie -
Authorize the That window is open in OHuth, but after clicking it is allowed if it is not going inside the window. The Settrol function is that the popup window is available in the Firefox and Chrome windows I am not locked in, how to solve it. You should open the login page in a new window, then a success page, which then closes the popup : page.html login.html success.html function (authorize_url, get_token, get_token_secret) {console.log ("ATTICON is" + received_token); Var win = window.open (authorize_url, "windowsman2", "width = 800, height = 600"); Var pollTimer = window.setInterval (function () {if (win.document.URL.indexOf (oauth_callback)! = -1) {console.log ("url" + + win.document.URL inside callback) window.clearInterval ( PollTimer); win.close (); getting_access_token (get_token, get_token_secret);}} hold (e) {}}, 100); }
function login () {var win = window.open ('', 'login.html', 'width = 800, height = 400 '); Win.focus (); }
window.location.href = 'success.html'; // or use server-side redirects
window.opener.close ();
Comments
Post a Comment