html <area> 标签 定义图像映射内部的区域(图像映射指的是带有可点击区域的图像)
<area> 元素始终嵌套在 <map> 标签 内部
<img> 标签 中的 usemap 属性 与 <map> 元素中的 name 相关联,以创建图像与映射之 间的 关系
提示 和注释:
注释:<img> 中的?usemap? 属性 可引用 <map> 中的?id?或?name? 属性 (由浏览器决定),所以我们需要同时向 <map> 添加 id 和 name 两个 属性 。
必需的 属性
属性
值
描述
alt
text
定义此区域的替换文本。
可选的 属性
属性
值
描述
coords
坐标值
定义可点击区域(对鼠标敏感的区域)的坐标。
href
URL
定义此区域的目标 URL。
nohref
nohref
从图像映射排除某个区域。
shape
default
rect
circ
poly
定义区域的形状。 target_blank
_parent
_self
_top
规定在何处打开 href?
实例
带有可点击区域的图像映射:
<img?src="planets.jpg"?border="0"?usemap="#planetmap"?alt="Planets"?/> <map?name="planetmap"?id="planetmap"> ??<area?shape="circle"?coords="180,139,14"?href?="venus.html"?alt="Venus"?/> ??<area?shape="circle"?coords="129,161,10"?href?="mercur.html"?alt="Mercury"?/> ??<area?shape="rect"?coords="0,110,260"?href?="sun.html"?alt="Sun"?/> </map>HTML <aside> 标签 ? ?HTML <address> 标签
声明:本文来自网络,不代表【好得很程序员自学网】立场,转载请注明出处:http://haodehen.cn/did92255