I’ve found that some browsers will set window.opener to window in certain cases. This is the most reliable popup check that I am using right now.
if (window.opener && window.opener !== window) {
// you are in a popup
}
I’ve found that some browsers will set window.opener to window in certain cases. This is the most reliable popup check that I am using right now.
if (window.opener && window.opener !== window) {
// you are in a popup
}