Forum Moderators: open
I thought this would be incredibly simple, but I wanted to create and Image Map so that one or two areas are selected by coordinates but the rest of the image linked to a default URL.
It works fine in Firefox, but in IE6 the default area does not link, only the area selected by the rectangle.
Any ideas?
The code is something like this:
<img src="image.gif" width="190" height="197" border="0" alt="Image" usemap="map1">
<map name="map1">
<area shape="rect" alt="Selected Area" coords="72,102,116,127" href="http://example.com/link1.html">
<area shape="default" href="http://example.com/default.html">
</map>
Thanks.
try it like this...
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
<title></title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css">
<!--
#theImage {
width:190px;
height:197px;
border:none;
}
-->
</style>
</head>
<body>
<div>
<img id="theImage" src="image.gif" alt="Image" usemap="#map1">
<map name="map1">
<area shape="rect" coords="72,102,116,127" href="http://example.com/link1.html" alt="" title="Selected Area">
<area shape="rect" coords="0,0,190,197" href="http://example.com/default.html" alt="" title="whole image">
</map>
</div>
</body>
</html>
birdbrain