AREA - of an image map
Description
The AREA tag describes an
individual area in an image map. An image map can contain several 'clickable'
areas, each with it's own destination URL if required. The AREA tag must be used
within the MAP tag.
Syntax
<AREA COORDS="coords" SHAPE="circle|rect|polygon"
HREF="location" NOHREF TARGET="windowName" ONMOUSEOUT="outJScode"
ONMOUSEOVER="overJScode" NAME="areaName">
COORDS must be specified, as must one of either HREF or NOHREF.
Attributes
COORDS values depend on the value of the SHAPE tag. If SHAPE
not specified, then assumed to be default which is RECTangle. The coords for
this would be x1,y1,x2,y2 where x1,y1 are the values of the upper left corner of
the rectangle, and x2,y2 are the coordinates of the lower right corner.
SHAPE specifies the shape of the map area. The possible values
are:
CIRCLE specifies a circle, where COORDS would be "x,y,r"
where x,y are the coordinates of the centre of the circel, and r is the radius
of the circle.
RECT specifies a rectangle. It is also the default shape if
SHAPE isn't specified. COORDS would be x1,y1,x2,y2 wherex1,y1 specifies the top
left corner of the rectangle, and x2,y2 specify the bottom right corner.
POLY or POLYGON specifies a polygon of up top 100 sides. COORDS
would be x1,y1,x2,y2,.....x100,y100 where eachxn,yn pair specifies a point where
two sides of the polygon meets. The final xn,yn pair is connected to the first
point, thus closing the polygon.
HREF specifies the URL to link to when area is clicked.
NOHREF specifies that no URL is linked to when area is clicked.
TARGET specifies the frame or window that the destination
document is loaded into (where the value of HREF is a URL that points to a
document.
ONMOUSEOUT specifies the JavaScript code to execute when mouse
is moved out of the area.
ONMOUSEOVER specifies the JavaScript code to execute when the
mouse is moved over or into the area.
NAME specifies the name of the area, so JavaScript can identify
the area objec
|