HTML属性(现在在HTML5中有效):
<a href="http://chriscoyier.net" target="_blank">This link will open in new window/tab</a>
内联JavaScript方式:
<a href="http://chriscoyier.net" onclick="window.open(this.href); return false;" onkeypress="window.open(this.href); return false;">This link will open in new window/tab</a>
使用jQuery:
翻译自: https://css-tricks.com/snippets/html/open-link-in-a-new-window/