O'Reilly logo

Microsoft® HTML5 Step by Step by Faithe Wempen

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Creating an Image Map

You have seen how to make an image function as a hyperlink, but sometimes you might want different areas of the image to hyperlink to different locations. For example, suppose you have a map of the United States, and you want the user to be able to click individual states to view a page containing information specific to her location. To create such an effect, you must use an image map.

An image map is an overlay for a graphic that assigns hyperlinks to specifically defined areas (hotspots) on the image. The hotspots can be rectangular, circular, or irregularly shaped (called a poly hotspot).

The position of a rectangular hotspot is defined by two points: its upper-left and lower-right corners. Each point is expressed as a ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required