The Friendliest Link Targets in the Neighborhood
[ Keywords: link, target, blank, replace, self, parent, top ]
The target attribute for anchor elements (<a>) specifies the location in which the referenced document should load. For example, to open a link in a new window, we would use a target value of _blank. Although this is a commonly employed technique, the target attribute has been deprecated by the W3C and is not valid (X)HTML. Regardless, the target element remains a useful tool for practicing designers and developers. Here, we present the attribute values for the target element:
Attribute values for the target element
- _blank
- [ Syntax:
target="_blank"]
— instructs the user-agent to load the target document in a new window. - _replace
- [ Syntax:
target="_replace"]
— instructs the user-agent to load the target document in a new window. - _self
- [ Syntax:
target="_self"]
— instructs the user-agent to load the target document in the current frame or window. - null value
- [ Syntax:
target=""]
— instructs the user-agent to load the target document in the current frame or window. - (no target specified)
- [ Syntax: (no target specified) ]
— instructs the user-agent to load the target document in the current frame or window. - _parent
- [ Syntax:
target="_parent"]
— instructs the user-agent to load the target document as the parental, or topmost, frameset or window. - _top
- [ Syntax:
target="_top"]
— instructs the user-agent to load the target document in the topmost window or frameset. - custom
- [ Syntax:
target="custom"]
— instructs the user-agent to load the target document in the frame identified as "custom" (i.e.,id="custom").
References
Related articles
- One Link to Open Them All
- Exploring the (X)HTML Link Element
- Embed Flash and Video via the object Tag
- Bare-Bones HTML/XHTML Document Templates
- A Complete CSS Template File
- XHTML Document Header Resource
- Unicode Character Reference for Bloggers
About this article
This is article #356, posted by Perishable on Wednesday, June 20, 2007 @ 03:33pm. Categorized as Structure, and tagged with attribute, code, html, links, markup, reference, xhtml. Updated on November 05, 2007. Visited 15528 times. 0 Responses »
Bookmark • Subscribe • Explore
« Wireless Internet: BlackBerry Curve as Bluetooth Modem for OS-X Mac • Up • June 21, 2007 »