设置图像热区连接

除了对整副图像设置超链接外,还可以将图像划分为若干区域,这叫做热区,每个区域设置不同的超链接,此时,包含热区的图像可以称为映射图像。(摘自书上)

基本语法。

<img src=图像地址  usemap="#映射图像名称">
<map name = "映射图像名称">
        <area shape="热区形状" coords="热区坐标"  href ="URL">
</map>

示例

<!DOCTYPE html>
<html>
    <head>
        <meta charset="UTF-8">
        <title>热像图区链接</title>
    </head>
    <body bgcolor="aquamarine">
        
            <img src="img/HH.jpg" align="bottom" width="400"  border="3" alt="知寒" usemap="#girl" >
      
            <map name = "girl">
                <area shape = "circle" href="http://www.baidu.com" coords="200,200,100" alt="百度">
            </map>
      
    </body>
</html>

截图

点击一下就会跳转到百度了

posted @ 2019-09-08 21:59  为挽月明  阅读(735)  评论(0)    收藏  举报
hello word


为挽月明© liclap@Foxmail.com