Link to home
Start Free TrialLog in
Avatar of blueshaolin
blueshaolin

asked on

Check if window is popup or not

Hi, I need to detect if the current window is a popup or not.

 I think opener won't work for me since I have already browsed some links in the window and I always get 'main window' after checking opener.

Thanks in advance !
ASKER CERTIFIED SOLUTION
Avatar of abel
abel
Flag of Netherlands image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of blueshaolin
blueshaolin

ASKER

Thanks..... the problem was that the 'current window' is in a frame, so the opener isn't really the Main page.

Solution: check window.parent.opener

I didn't give enough information since I didn't know the page/window was a frame. The solution to the given problem is right!
glad you found it. Thanks for giving me the credits still for answering to the original q. :)