Ramen said:
I can't think of any legitimate use. It's something that should be banned
or whatever.
I think you have an excellent point here. When and how implementing and
coding a popup can be a defendable and responsible web page design
decision and can promote the user's experience instead of alienating it?
If popups design decision always have a working and better alternative,
then popups should never be used.
Here's one usage.
Analysis: opening enlarged images of different dimensions. You can't use
an iframed (or div) slideshow (unless working around this with coding)
because of different dimensions. You could always just link the
referenced resource so that the enlarged image could load in the same
window. But let's say you have many thumbnails (or descriptive link
texts) in the same page: then a popup makes sense.
You can then code the title attribute, add an icon to the link to notify
in advance the user that clicking the link will create a secondary window.
"10.1 - Until user agents allow users to turn off spawned windows, do
not cause pop-ups or other windows to appear and do not change the
current window without informing the user."
http://www.w3.org/WAI/wcag-curric/chk11-0.htm
"8. Use link titles to provide users with a preview of where each link
will take them, before they have clicked on it."
Ten Good Deeds in Web Design
http://www.useit.com/alertbox/991003.html
"a warning given before a pop-up window(...) warning users of context
changes in advance minimizes confusion when the user discovers that the
back button no longer behaves as expected. (...) At the beginning of
each link is an icon of an arrow with the text equivalent, 'Link will
open in new window.'"
Web Content Accessibility Guidelines 2.0
You can code the link so that only 1 secondary window will be created if
another link (for the purpose of showing an enlarged image) is clicked.
You can code the link so that it will not limit the freedom of the user
via user prefs (or right-click contextmenu options) nor the browser
flexibility on how to load a link (in background for window or for tab,
in a tab, in the same window, in another unnamed separate window, with
javascript support disabled).
The reasons that so many people hate popups are never enough explained,
detailed and explicited actually.
- Popups open without the user being wittingly and willingly involved
into such process without an explicit, aware action. Typically, that's
unrequested popups (created with an onload event of the opener). WAI
recommends to avoid "extreme changes in [visual] context" in its current
working draft document. Even requested popups (the user clicked a link)
are often coded without giving the user of a sound warning and deprive
the user of any control, even its right-click contextmenu: typically,
that's the href="javascript:functionName();" which even confuse
browsers. Some code popups so that they close as soon as losing focus:
that's as equally bad as opening them unexpectedly.
The general overall attitude is that web authors try to impose their
viewing preferences, their website rigid scenario instead of coding
along with and in accordance with the freedom of their visitors. More
could be said on this.
- Web authors try to remove basic standard functionalities of the users'
browsers (resizability, scrolling, statusbar, toolbars, etc). To reach
absolute control, web authors try to create a secondary window which is
greatly disabled and then try to close its opener.
- Popups break normal flow of events, normal experience of a webpage;
the user has to click to close un-recyclable "_blank" ones otherwise
they add up. That's the nr 1 consequence of thoughtless target="_blank"
popups.
- Generally speaking, popups are coded without any concerns for
accessibility to content, usability of window, scalability of web page,
users' system resources and users' awared control and explicit consent.
E.g.: if an user needs to increase text size because he has weak
eye-vision (and that's the case for a majority of users over 40 years
old), then the content will overflow requested window dimensions making
the content clipped. Since the author removed window resizability and
scrollbars, the user can't access the content and is penalized.
E.g.: the nr 1 problem with popups is that a wide majority of authors
can not code popups in a way to compensate an inherent flaw in the
window management system of operating system when multiple windows are
involved. When the opener has focus and is covering the popup, if the
user is clicking the link again, the popup will not be brought back on
top of the opener. So, the user gets frustrated and is confused. Some
web authors realize this but their solution is pretty bad: they destroy
the popup and then re-create and re-load the exact same popup again...
all this by abusing the users' system resources.
- Popups are widely and generally poorly coded: wrong positions or
excessive dimensions which will be internally corrected/adjusted by the
browser during execution-rendering time, window.open() calls don't work
exactly the same way on most browsers, popups are not brought back in
front of the opener, web authors limit choices and freedom of users with
the typical href="javascript:functionName();", with toolbars and
functionalities removed (1), disabled, etc.. Whenever something goes
wrong with the code of popups, only the users suffer from this: the
authors generally are not even aware of the problems their code creates.
- Many years ago, browser manufacturers gave way too much power to
authors to "toy" with the window.open() function. Pop-unders are a good
proof of that. Things have changed with Mozilla and Opera browsers: also
popup blockers and proxomitron are now normal and established add-ons to
web surfers, just like anti-virus and firewall softwares.
These days, the fashion is to reassign the opener reference of a popup.
Back then and still now, browser manufacturers are responsible for
allowing way too much latitude and powers to web authors here.
DU
(1) Unable to Maximize or Resize Internet Explorer Pop-Up Windows
"You cannot maximize or resize new Internet Explorer windows that are
created or opened by a Web site. As a result, you may be unable to view
some of the content in the new window (for example, if the new window
does not display scroll bars)."
http://support.microsoft.com/default.aspx?scid=kb;en-us;211068