HTML DOM noHref ÊôÐÔ

¶¨ÒåºÍÓ÷¨

noHref ÊôÐÔ¿ÉÉèÖûò·µ»ØÄ³¸öÇøÓòÊǻµÄ»¹ÊǷǻµÄ¡£

Óï·¨

areaObject.noHref=true|false

˵Ã÷

<area> ±êÇ©µÄ nohref ÊôÐÔÔÚ¿Í»§¶ËͼÏñÓ³ÉäÖж¨ÒåÁËÒ»¸ö¶ÔÊó±êÃô¸ÐµÄÇøÓò£¬¶ø¸ÃÇøÓò²»»áÔÚÓû§Ñ¡È¡Ëüʱ²ÉÈ¡ÈκβÙ×÷¡£Äã±ØÐëΪÿ¸ö <area> ±êÇ©¶¼°üº¬Ò»¸ö href »ò nohref ÊôÐÔ¡£

ʵÀý

ÏÂÃæµÄÀý×Ó¿É·µ»ØÍ¼ÏñÓ³ÉäÖÐ "Venus" ÇøÓòµÄ "noHref" ״̬£º

<html>
<body>

<img src="planets.gif" 
width="145" height="126" 
usemap="#planetmap" />

<map name="planetmap">
<area id="venus" shape="circle" 
coords="124,58,8" 
alt="Venus"
href="venus.htm" />
</map>

<p>noHref status:
<script type="text/javascript">
x=document.getElementById('venus');
document.write(x.noHref);
</script>
</p>

</script>
</body>
</html>
VUE