This is one of those things I keep having to look up. It involves the old
target
attribute you use in
<a>
links to open the link in a new window. This attribute is deprecated in XHTML strict and HTML 4.0 -- or so I hear.
Here, in any event, is the workaround:
onclick="window.open(this.href,'_blank');return false;"
So this:
<a href="http://www.flametag.com" target="_blank">flametag.com</a>
Would become this:
<a href="http://www.flametag.com" rel="external" onclick="window.open(this.href,'_blank');return false;">flametag.com</a>
(The
rel
attribute is not necessary but can be used for javascript functions to the same effect.)
credit:
phpfreaks.comkeywords: link, links, anchor, blank, _blank, target, xhtml