javascript - window.opener is not working in Facebook App on the iOS devices -


in facebook app, have created fb page in added test button url. when click on button loads page test1.html in new tab app. in page test1.html page, have button login, when click on login, open child window test2.html, after oauth has done, closes child window , comes parent window. flow.

for communicating child window parent window i'm using window.opener works everywhere except in facebook app on ios device.

code: test1.html

 var login  = (function() {  var events = function() {                $('#login_button').off('click').on('click', function() {                 newwindow("/login.do");                });              }  var newwindow = function(url) {                   window.open(url,'oauth',"width=600,height=600");                  }  var customerdetails = function(resp,callback) {                         console.log(resp);                         if(callback && typeof(callback) ==="function"){                            callback();                          }                         } })(); 

code: test2.html

 var self_close = function() {                         self.close();                      }    window.opener.login.customerdetails(message,self_close); 

when print window.opener, it's throwing null. appreciated


Comments

Popular posts from this blog

python - Operations inside variables -

Generic Map Parameter java -

arrays - What causes a java.lang.ArrayIndexOutOfBoundsException and how do I prevent it? -