How to write your own ImageMap stuff

It's not hard. Really, it's not.

You just need a chunk of HTML that looks like this:

<a href="http://www.mit.edu:8001/img/URL"><img src="/URL/of/image" ISMAP></a>

The hypertext-reference (href) of the link should be a valid absolute URL on www.mit.edu, prepended by "http://www.mit.edu:8001/img". For example, "/html/map-etc/imageconf.test" can be fetched on www.mit.edu, so, for it, you should use the href "http://www.mit.edu:8001/img/html/map-etc/imageconf.test". This URL should point to a imagemap configuration file, which should be ordinary ASCII, and should follow the format explained in CERN's documentation on this program.

Basically, this format allows four directives, and the imagemap program will return the first directive (excepting the default) which matches the query.

If the start and endpoints of a polygon don't match, the final segment of the polygon will be between these two points.

There's a imagemap configuration utility called mapedit in the outland locker which can be used on Athena workstations. To use it, type "add outland ; mapedit" at your athena% prompt.

The image source ("/URL/of/image") should be an ordinary URL you'd use for an inlined image. If you want people to be able to view this image inlined in Mosaic, you can only use GIFs and X Bitmap (.xbm) format images.

I wrote an example imagemap that uses all the available mapping directives.


Please feel free to let me know what you think, or ask me for help with this. You might actually want to send your mail to webmaster instead.

-Eric Mumpower (nocturne@mit.edu)