HTML <a name/> Anchor Tag Obsolete


ATTENTION: THIS PAGE IS Valid HTML 5 AND IS BEST VIEWED WITH HTML 5 - Please upgrade your browser or download one of the HTML 5 compatible browsers such as Mozilla Firefox, Chrome, Opera or IE 9 (March 14, 2011 or later). For more information see HTML 5 browsers.

If you find this helpful, please click the Google +1 Button to the left, if it is white, to make it turn blue or red. Thank you! (It also helps find this page again more easily.)

PDF mobile

Avoid <a name/> and <a id/> without href, now obsolete

The <a name/> or <a id/> without the href attribute no longer defines an anchor that can be used as the target of a hypertext link. When the href attribute is not coded on the <a> tag, it defines a placeholder link, with a target that can later be specified with dynamic script code.

See Changes to the <a> Tag in HTML for more informaiton.

To create a placemark (anchor) for the target of a hypertext link, code an id global attribute on any HTML tag at the target location.

For backward compatibility, most browsers will treat the name attribute on elements where it is not supposed to be code as if it were an id attribute. Since the value of the id attribute must be unique, the same value should never be used for any other id or name attribute within the same document.

See id global attribute for more information on creating a placemark (anchor).

Valid HTML 5