Answer the question
In order to leave comments, you need to log in
How to work with window.open in firefox (does not give access to the parent window)?
I do OAuth authorization from social networks, through a popup window in which a page opens https://sitename.ru/Account/RegisterVk
that requests information from a social network using the AOAuthNET library . The popup opens like this:
var params = 'menubar=no,location=yes,resizable=no,scrollbars=no,status=no,width=900,height=500',
win = window.open(url, name, params);
https://sitename.ru/Account/RegisterVkResult
, which receives a code to access user data, authorizes it and prescribes a cookie, and then returns a page with a script of the following content:window.opener.LogOnSuccess('OK');
window.close();
https://sitename.ru
(without www). www.sitename.ru
to sitename.ru
Answer the question
In order to leave comments, you need to log in
The problem was solved with an incomprehensible crutch:
If on the page in the pop-up, before calling window.opener, you call a redirect to itself (that is, just document.location = 'https://sitename.ru/Account/RegisterVkResult'), then access appears.
If anyone can explain the reasons for this phenomenon, I would be extremely grateful.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question