Getting hold of the image map

There are at least two cases where the basic StrokeCSIM() method will not work. Basically this is limited to only showing the graph in one HTML page and nothing more. So the cases where this needs to be handled differently are

  1. In the case where you want to store the image on disk and later use it in an img-tag you need to get hold of the image map.

  2. In order to include multiple CSIM images ona a WEB-page. (This is not entirely true though, it is possible to include several CSIM graph images with the use of the <iframe> tag. This in effect creates it's own WEB page within the WEB page but we will not discuss this further here.

To get hold of the image map the function Graph::GetHTMLImageMap() should be used. This returns the coordinates for the hotsposts

An example of the use of this is shown below. With these lines the image will be written to a file. The script then returns a HTML page which contains the Client side image map and an img-tag which will retrieve the previously stored file.

$graph -> Stroke ( "/usr/local/httpd/htdocs/img/image001.png" );
echo  $graph -> GetHTMLImageMap ( "myimagemap001" );
echo  "<img src=\"img/image001.png\" ISMAP USEMAP=\"#myimagemap001\" border=0>" ;