ในการรับค่าแอตทริบิวต์ usemap ของรูปภาพ ให้ใช้ useMap คุณสมบัติ. คุณสามารถลองเรียกใช้รหัสต่อไปนี้เพื่อแสดงค่าแอตทริบิวต์ usemap -
ตัวอย่าง
<!DOCTYPE html>
<html>
<body>
<img id = "myid" src = "/images/html.gif" alt = "HTML Map" usemap = "#html"/>
<map name = "html">
<area id = "myarea" shape = "circle" coords = "154,150,59" href = "about.htm" alt = "Team" >
</map>
<script>
var x = document.getElementById("myid").useMap;
document.write("<br>Usemap: "+x);
</script>
</body>
</html>