Get your own website Result Size: 625 x 565
x
 
<!DOCTYPE html>
<html>
<body>
<img src="planets.gif" width="145" height="126" usemap="#myMap">
<p>Click the button to create an IMAGE-MAP and an AREA element with a link to "venus.htm".</p>
<button onclick="myFunction()">Try it</button>
<p id="demo"></p>
<script>
function myFunction() {
  var x = document.createElement("MAP");
  x.setAttribute("id", "myMap");
  x.setAttribute("name", "myMap");
  document.body.appendChild(x);
  var y = document.createElement("AREA");
  y.setAttribute("href", "venus.htm");
  y.setAttribute("shape", "circle");
  y.setAttribute("coords", "124,58,8");
  document.getElementById("myMap").appendChild(y);
  document.getElementById("demo").innerHTML = "The MAP was created, and you can now click on the venus area in the image.";
}
</script>
</body>
</html>