Standard Compliant Way to Open a New Page (no target tag)


/ Published in: HTML
Save to your folder(s)

Very simple standard compliant way of opening a page in a new window. Since XHTML 1.0 Strict doesn't allow the target attribute in the tag. This method isn't recommended, use the DOM folks! See "Standard Compliant Way to Open a New Page Function" in my other snippets of code.


Copy this code and paste it in your HTML
  1. <a href="http://address.com/" title="Title Here" onclick="window.open(this.href,'newwin'); return false;">Insert Link Title</a>

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.