HTML <a> shape Attribute
HTML <a> Tag
Example
Using shape and coords in the <a> element to create an image map:
<object data="planets.gif" alt="Planets" type="image/gif" usemap="#Map1">
<map name="Map1">
<a href="sun.htm" shape="rect" coords="0,0,82,126">Sun</a>
<a href="mercur.htm" shape="circle" coords="90,58,3">Mercury</a>
<a href="venus.htm" shape="circle" coords="124,58,8">Venus</a>
</map>
</object>
Browser Support
Currently, only Firefox and Opera support the shape attribute.
Definition and Usage
The shape attribute, in conjunction with the coords attribute, specifies the size, shape, and position of the link in an <object> or <img> element.
Tip: To create an image map that works in all browsers, use the <area> element!
Syntax
Attribute Values
| Value |
Description |
| default |
Specifies the entire area. |
| rect |
Defines a rectangular area. |
| circle |
Defines a circular area. |
| poly |
Defines a polygonal area. |
HTML <a> Tag