Answer the question
In order to leave comments, you need to log in
Why does yii2-authclient use js redirect to user's returnUrl?
Which is very strange and does not always work, because. there are problems with js on the mobile version, users often refresh the page and get the expected error. Wouldn't it be better to do the redirect using the backend?
Answer the question
In order to leave comments, you need to log in
I looked at the source and this is what I found .
function popupWindowRedirect(url, enforceRedirect)
{
if (window.opener && !window.opener.closed) {
if (enforceRedirect === undefined || enforceRedirect) {
window.opener.location = url;
}
window.opener.focus();
window.close();
} else {
window.location = url;
}
}
popupWindowRedirect(<?= Json::htmlEncode($url) ?>, <?= Json::htmlEncode($enforceRedirect) ?>);
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question