Is there a way to determine if the current window is a popup? This is what I have right now but for some reason it is not working. I am trying to make sure that certain pages are only shown in popup window.
if(!opener)
window.location = 'error.php';
The value of opener is [object DOMWindow] even though the window is not popup.