Image map: Difference between revisions

Content deleted Content added
Pure HTML: quote marks for literal strings
Line 25:
Shape-Values are coordinate-pairs. Every pair has an X and a Y value (from left/top of an image) and is separated with a comma.
 
* Rectangle: Set four coordinates: "x1,y1,x2,y2"
* Polygon: Set as many coordinates as desired (a multiple of two): "x1,y1,x2,y2, [...] xn,yn"
* Circle: One coordinate-pair and another value with a radius: "x1,y1,radius"
 
The following example defines a rectangular area ("9,372,66,397"). When a user clicks anywhere inside this area, they are taken to the [[English Wikipedia]]'s home page.
<syntaxhighlight lang="html4strict">
<img src="image.png" alt="Website map" usemap="#mapname" />