HTML area target Attribute
HTML <area> tag
Definition and Usage
The target attribute specifies where the URL (web resource) should be opened.
Syntax
Syntax Example
Attribute Values
Value |
Description |
_blank |
The target URL will open in a new window. |
_self |
The target URL will open in the same frame as it was
clicked. |
_parent |
The target URL will open in the parent frameset. |
_top |
The target URL will open in the full body of the window. |
framename |
The name of the target frame the URL should open in. |
Browser Support
The attribute is supported in all major browsers.
Example
Source |
Output |
<p>Click on one of the planets:</p>
<img src ="planets.gif" width="145" height="126" alt="Planets" usemap ="#planetmap"
/>
<map id ="planetmap"
name="planetmap">
<area shape="rect" coords ="0,0,82,126" href ="sun.htm" target ="_blank"
alt="Sun" />
<area shape ="circle" coords ="90,58,3" href ="mercur.htm" target ="_blank"
alt="Mercury" />
<area shape ="circle" coords ="124,58,8" href ="venus.htm" target ="_blank"
alt="Venus" />
</map>
|
Click on one of the planets:
|
Try-It-Yourself Demos
area target
attribute example
Set the target window of the link in the image map.
HTML <area> tag
|