Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Image hyperlink position

I'm not sure if this is possible or not.

Is there a way to put a hyperlink on a specific coordinate on a image?

Ex

_____________________________________
|                                   |
|   xxx                             |
|   xxx                             |
|                                   |
|                                   |
|                                   |
|                    zzz            |
|                    zzz            |
|                                   |
|___________________________________|

Is there a way to set hyperlink on xxx position and a separate hyperlink on the zzz position of the image. How would I go about starting this?

like image 517
Thao Nguyen Avatar asked Jun 21 '26 08:06

Thao Nguyen


2 Answers

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

<map name="planetmap">
<area shape="rect" coords="0,0,82,126" href="sun.htm" alt="Sun">
<area shape="circle" coords="90,58,3" href="mercur.htm" alt="Mercury">
<area shape="circle" coords="124,58,8" href="venus.htm" alt="Venus">
</map>

more info about HTML coords Attribute http://www.w3schools.com/tags/att_area_coords.asp

like image 82
Saleem Avatar answered Jun 22 '26 20:06

Saleem


Yes, it can be done with <map>

<map name="a">
  <area shape="rect" coords="25,25,75,75" href='url'>
</map>
<img usemap="#a" src=image.png>
like image 33
Musa Avatar answered Jun 22 '26 20:06

Musa