Private archive copy · Unofficial site · Content copyright belongs to Runoob Tutorial and the original authors · View Original

HTML DOM Image useMap property

Image useMap property

Image Object Reference Image Object


Definition and Usage

The useMap property sets or returns the value of the usemap attribute of an image.

The usemap attribute specifies a client-side image map of an image (an image map with clickable areas).

The usemap attribute is related to the name attribute of the map element; together they create the association between the image and the map.

Syntax

imageObject.useMap=

value

The useMap property can have the following values:

Value Description
#mapname A hash character ("#") followed by the name of the map element

Browser support

Internet ExplorerFirefoxOperaGoogle ChromeSafari

All major browsers support the useMap property


Example

Example

Return the value of the usemap attribute of the client-side image map:

Runoob Tutorial(runoob.com) The planet Venus

The value of the usemap attribute:

Try it »


Image Object Reference Image Object