Popup or not popup that is the question

I hate pop ups, so as surely many of you now, I installed the Google bar with the popup blocker.

But one issue is coming now. I have some web projects where after a login page, I need to open the main window full screen without the menu bar or any decorations.

I am puzzled now how I am going to fix my Javascript code because obviously my legitimate new window has been considered legitimately by Google bar as a popup !

So what I am supposed to do now ? Very annoying, because of course I can click on Ctrl to open my new window, but what's about the users ? It make things complicated.

Including the fact that this feature will be part of the next IE, and i believe activate by default. I would like to see a little bit of intelligence in the behavior of these pop up blockers. Like for example that if a window.open is called from the same site, it consider this as perfectly valid.
I know a lot of webtools working with full opened windows, I wonder how they will fix this.

Any ideas ?

10 Comments

  • Well, for the Google toolbar you can allow popups from specific domains. On your site, click the "xxx blocked" button on your toolbar and you should be set.

  • If you click on the "# blocked" button in Google tool bar, you can disable the popup blocker only for the site.

  • That's exactly how it should work...It doesn't need "fixing". The worst pop-up offenders are sites that work exactly that way. Not sites like yours, but, for instance, the sites that prey on domain name misspellings. Transpose two letters in "Microsoft.com", and you'll likely as not find yourself at a site that fires twenty consecutive pop-ups at you. I don't want to have to deal with that.



    Secondly, you're fighting a losing battle, if you're doing it to hide the menu/tool bars. Again, for instance, I don't appreciate having my menu bar hidden, so I have my browser (Mozilla Firebird) configured to not allow that sort of behavior. My menu bars show up regardless of whether or not the developer has tried to hide them.



    If you really want that kind of control over the user environment, you need to move away from the open world of HTML/Javascript, and start developing on a platform that gives you that kind of control, such as Flash.



    Regards,



    Xander

  • Chris, thanks for that but I know of course I can do it. My question is more about the other users, the one I don't know. The effect of the script is that it clode my own window wthout warning.

    so unless I put a warning on the login page to say click on the buttn Login with the Ctrl key, I don't seem to find a solution. As I said in my post, I don't like popups, but in this case, when you have an admin page, you don't talk about popup but just windows, nothing less. and I need the maximum real estate on the page.

  • Xander, I am sorry but you can find today a lot of applications running like this without any menubar. did you ever looked closely at most of the Cds you find in computer magazines. Their content is simply based on a web browser without menu bar. Here maybe I was not clear enough, but I talk about an admin website, and not about a general website.

    And Flash, no way if it's to manage a database !

  • >, I am sorry but you can find today a lot of applications

    >running like this without any menubar.



    Sure, but not because they need to. Why do those applications need to be run without a menu bar?



    >And Flash, no way if it's to manage a database !



    Again, sure...But you've got a trade-off there. Do you want to have control over the way the application looks, or do you want easy development?

  • Well, if you check out any other browser that actually has integrated popup blocking you'll discover intelligent popup blocking is nothing new. If the user is the one who invoked the window.open through a click, it works. If it was caused by an event (like page load, or page leave), then it's blocked. Simple.



    IE popup blockers are junk in this regard because they can't know, they sit on the sidelines and guess. And they guess wrong a lot.



    IE 6.05's popup blocker may be intelligent since it's likely to be properly integrated into the javascript stack itself -- But since the rest of IE is such a mess, I'm not holding my breath ;)

  • The other day, I saw a website which was using popups and since I use the Google Toolbar to prevent windows to popup, the website detected it and displayed a message like :



    "Your browser seems to block the opening of popup windows."



    It then displayed a link to display the page within the same browser page or to ask the user to allow popups for this website.



    Technically, I think it could be pretty easy to test this out. On the parent or opener window, the code to open the window could be like :



    wndOptions = 'width=400,height=250,toolbar=1,resizable=1,status=1,scrollbars=1';

    wnd = window.open('<a target="_new" href="http://www.google.com">http://www.google.com','Google',wndOptions);

    if (wnd) // or maybe if(wnd = window.open('<a target="_new" href="http://www.google.com">http://www.google.com','Google',wndOptions)

    )

    {

    wnd.focus();

    }

    else

    {

    // Show message explaining popup opening failed

    }



    I didn't test that out. Hope this helps !

  • i have a large application which opens the main interface in a kiosk-mode IE window. i had to tell my googlebar to allow this behaviour. but i think that if a user is compenent enough to download and install a popup blocker, then they should be smart enough to use it properly!

  • Well I've been fighting with the same issues.

    Displaying a message such as &quot;Your browser seems to block the opening of popup windows&quot; or asking the end user to mark my site as a trusted site isn't a good option. End users may be reluctant to do so (atleast a few among the thousands).

    I still think that the same window can be re-used by removing the location bar and menu bar, but am not sure of how to do it.

    Has anyone heard of Signed Scripts and experimented with them?

Comments have been disabled for this content.