Content deleted Content added
image map tab order, default rect |
→Creation and use: rm examplefarm |
||
(14 intermediate revisions by 12 users not shown) | |||
Line 1:
{{Short description|Method of adding links to parts of an image}}
{{More citations needed|date=September 2023}}
In [[HTML]] and [[XHTML]], an '''image map''' is a list of coordinates relating to a specific [[image]], created in order to [[hyperlink]] areas of
==Server-side==
'''Server-side image maps''' were first supported in [[Mosaic (web browser)]] version 1.1.<ref>{{cite web|url=http://1997.webhistory.org/www.lists/www-talk.1993q2/0343.html|title=IMG extension for Mosaic 1.1}}</ref>
The [[HTML]] code for this type of
<syntaxhighlight lang="
<a href="/imagemapper"><img src="image.png" ismap /></a>
</syntaxhighlight>
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
* 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="
<img src="image.png" alt="Website map" usemap="#mapname" />
<map name="mapname">
Line 38:
===CSS===
A more
==Creation and use==
Line 64:
It is possible to create client-side image maps by hand using a text editor, but doing so requires web designers to know how to code HTML as well as how to enumerate the coordinates of the areas they wish to place over the image. As a result, most image maps coded by hand are simple polygons.
Because creating image maps in a text editor requires much time and effort, many applications have been designed to allow web designers to create image maps quickly and easily, much as they would create shapes in a [[vector graphics editor
Image maps which do not make their clickable areas obvious risk subjecting the user to [[mystery meat navigation]]. Even when they do, where they lead may not be obvious. This can be partially remedied with rollover effects.<ref>{{cite book
|