
Image maps are farely simple if you have a program that will generate the map file for you. If you do not have one you might want to go to shareware.com and get one.
Below is a very basic example of an image map- try it out.
This example was produced by the two HTML tags below...
<A HREF="/cgi-bin/imagemap/help/gadgets/imagemap.map"> <IMG ISMAP SRC="/images/imagemap.gif" border="0" > </A>
The first line starts an 'anchor' that includes your image. The image is defined with the ISMAP parameter and the anchor is ended after the image. This means that the client will jump to the /cgi-bin/imagemap URL when the image is clicked upon. That CGI script will then use the co-ordinates of the click and look up a URL to jump to in the specified file (/help/gadgets/imagemap.map) in the example above. Just to be clear: the "/cgi-bin/imagemap" part of the HREF is actually the path to a cgi program. The following "/help/gadgets/imagemap.map" is the path to the map file. Here's the imagemap.map file...
rect /help/ 0,0 50,50 rect /help/gadgets 100,0 150,50 default /cgi-bin/nph-no_op.sh
The default action shown in the file is a special one. The server tells the client (browser) not to do anything, since the click was outside any of the active regions. The other shapes available are 'circle' (which takes a center and an edgepoint as co-ordinates), 'point' (which takes only one pair of co-ordinates), 'poly' (which takes an arbitrary number of co-ordinates), and the shown 'rect' and 'default' shapes. The point shape is only usefull with other point shapes; the image map script simply finds the closest point and returns the corresponding URL.