I'm trying to create an image map, formatted so when an area on the map is clicked the browser opens the chosen link in a new tab.
I know to use the target_blank attribute to do this, and this works when I have a specific image as the "button". But I can't figure out how to get it to work on the image map.
The enclosed code works fine as an image map, but I want to include the functionality of having the link open in a new tab.
Here's the code:
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
</head>
<body>
<div>
<map name="pdx">
<area href="https://en.wikipedia.org/wiki/Main_Page" alt="wiki"
target="_blank" shape="rect" coords="300,200,400,800">
</map>
</div>
<p>
<img src="/1st-stark1852WebCover.jpg" width="1800" alt="pdx_1852" usemap="#pdx"/>
</p>
</body>
</html>