The forums ran from 2008-2020 and are now closed and viewable here as an archive.

Home Forums Other HTML code for launching a link in a new window… Re: HTML code for launching a link in a new window…


Works fine for me.

I must warn you: generally opening links in a new window is bad UX. It isn’t as common any more, with the only exception being when clicking an external link (and you probably shouldn’t use it for that either, at least not without using an icon to indicate it). If your site is useful, visitors will come back.

Users don’t like control being taken away from them. They like being able to choose whether or not they want to open a link in a new window, not have that decision made for them. Also, opening a link in a new window doesn’t carry across the original window’s history, which means the back button becomes useless.

TL;DR think carefully before simply opening all links in a new window, it just might annoy your users more than it helps them.