x
 
<!DOCTYPE html>
<html>
<body>
<img src="/i/html/planets.jpg" border="0" usemap="#planetmap" />
<map id="myMap" name="planetmap"></map>
<p>点击该按钮可创建一个带有 “venus.html” 链接的 AREA 元素。</p>
<button onclick="myFunction()">试一试</button>
<p id="demo"></p>
<script>
function myFunction() {
  var x = document.createElement("AREA");
  x.setAttribute("href", "/demo/tags/venus.html");
  x.setAttribute("shape", "circle");
  x.setAttribute("coords", "180,139,14");
  document.getElementById("myMap").appendChild(x);
  document.getElementById("demo").innerHTML = "AREA 元素已创建,您现在可以单击图像中的金星区域。";
}
</script>
</body>
</html>