16. XHTML Server-Side Image Map Module

This section is normative.

The Server-side Image Map Module provides support for image-selection and transmission of selection coordinates. It requires that the Object Module (or another module that supports the object element) be included. The Server-side Image Map Module supports the following attributes:

Elements Attributes Minimal Content Model Notes
img& ismap ("ismap") n/a  
input& ismap ("ismap") n/a When the Forms Module is selected.

Implementation: DTD

ismap = "ismap"
This attribute indicates that the associated image is to be treated as a "server-side image map". When selected, the coordinates within the element that the user selected are sent to the server where the document resides. Screen coordinates are expressed as screen pixel values relative to the image, and start at (0,0) at the top left corner.

In the following example, the active region defines a server-side link. Thus, a click anywhere on the image will cause the click's coordinates to be sent to the server.

<p href="http://www.example.com/cgi-bin/map"
      src="map.png" ismap="ismap">
   Our location.

The location clicked is passed to the server as follows. The user agent derives a new URI from the URI specified by the href attribute of the a element, by appending `?' followed by the x and y coordinates, separated by a comma. The link is then followed using the new URI. For instance, in the given example, if the user clicks at the location x=10, y=27 then the derived URI is "http://www.example.com/cgi-bin/competition?10,27".

User agents that do not offer the user a means to select specific coordinates (e.g., non-graphical user agents that rely on keyboard input, speech-based user agents, etc.) should send the coordinates "0,0" to the server when the link is activated.