Тег <map></map>




Этот тег определяет контейнер для тега <area />.




index.html
  • <!DOCTYPE html>
  • <html>
  • <head>
  •  <meta charset="utf-8" />
  •  <title>New Page</title>
  • </head>
  • <body>
  •  <div>
  •   <img src="img/a.jpg" usemap="#map1"/>
  •   <map name="map1">
  •    <area href="red.html" target="_blank" shape="rect" coords="0,0,200,200" alt="red" />
  •    <area href="green.html" target="_blank" shape="rect" coords="200,0,400,200" alt="green" />
  •    <area href="blue.html" target="_blank" shape="rect" coords="0,200,200,400" alt="blue" />
  •    <area href="yellow.html" target="_blank" shape="rect" coords="200,200,400,400" alt="yellow" />
  •   </map>
  •  </div>
  • </body>
  • </html>
  • <!DOCTYPE html>
  • <html>
  • <head>
  •  <meta charset="utf-8" />
  •  <title>New Page</title>
  • </head>
  • <body>
  •  <div>
  •   <img src="img/a.jpg" usemap="#map1"/>
  •   <map name="map1">
  •    <area href="red.html" target="_blank" shape="rect" coords="0,0,200,200" alt="red" />
  •    <area href="green.html" target="_blank" shape="rect" coords="200,0,400,200" alt="green" />
  •    <area href="blue.html" target="_blank" shape="rect" coords="0,200,200,400" alt="blue" />
  •    <area href="yellow.html" target="_blank" shape="rect" coords="200,200,400,400" alt="yellow" />
  •   </map>
  •  </div>
  • </body>
  • </html>