asp.net.ph

Skip Navigation Links

TARGET Attribute | target Property

Language References


Specifies the window or frame in which to load the contents of a hyperlink.

Applies To: A   AREA   BASE   FORM

Syntax


Inline <element target = _blank | _parent | _self | _top | strTarget...>
Script object.target = _blank | _parent | _self | _top | strTarget

Possible Values


_blank Loads the linked document into a new blank unnamed window.
_parent Loads the linked document into the immediate parent of the document the link is in.
_self Loads the linked document into the same window the link was clicked in ( the active window ).
_top Loads the linked document into the topmost window.
strTarget Loads the linked document into a named window or frame.

The property is read/write with a default value of _self.

Remarks

If there is no frame or window that matches the specified target, a new window is opened for the link.

The default value for target depends on the URL and site. If the user does not leave the site, the default is _self, but if the user exits to a new site, the default is _top.

Example

In the following example, the link will load the page into a new blank window.

<a href="next.html" target="_blank">Next Page.</a>
Applies To

A   AREA   BASE   FORM

See Also

How HyperText Links Work



© 2025 Reynald Nuñez and asp.net.ph. All rights reserved.

If you have any question, comment or suggestion
about this site, please send us a note