Easy Tutorial
❮ Sel Element Gt Pr Object Position ❯

CSS3 target Attribute

Example

Open all hyperlinks in a new window and place all other tags/windows above it:


Browser Support

No major browsers support the target attribute.


Attribute Definition and Usage

The target attribute is a shorthand property for setting the target-name, target-new, and target-position properties.

Default value: current window above
Inherited: no
--- ---
Version: CSS3
--- ---
JavaScript syntax: object.style.target="new front"
--- ---

Syntax

Value Description
target-name Specifies where to open the hyperlink (target destination).
target-new Specifies whether the hyperlink should open in a new window or a new tab in an existing window.
target-position Specifies where to place the new destination link.

Note: The target-new and target-position values are only effective when the target-name value creates a new tab or window.

❮ Sel Element Gt Pr Object Position ❯