// reproduce the following code -- take from Front Page
// This displays an image map and the associated links
// this file is here to keep the image stuff in one place.

//<!--webbot bot="ImageMap" 
//    rectangle="(8,234) (63, 251)  wince/index.htm" 
//    rectangle="(8,216) (96, 234)  what_new.htm" 
//    rectangle="(8,200) (47, 216)  tips/index.htm" 
//    rectangle="(8,167) (78, 200)  techref/index.htm" 
//    rectangle="(8,137) (86, 167)  oo/index.htm" 
//    rectangle="(8,106) (96, 137)  swpm/index.htm" 
//    rectangle="(8,89) (84, 106)  databases/index.htm" 
//    rectangle="(8,73) (79, 89)  java/index.htm" 
//    rectangle="(8,55) (89, 73)  downloads/index.htm" 
//    rectangle="(8,38) (94, 55)  bibliography.htm" 
//    rectangle="(8,20) (59, 38)  COM/index.htm" 
//    rectangle="(8,2) (72, 19)  index.htm" 
//    src="images/MainMenu2c.gif" alt="Main Menu" 
//    onMouseOver="window.status='Main Menu'; return true;" 
//    border="0" startspan -->
//    <MAP NAME="FrontPageMap">
//    <AREA SHAPE="RECT" COORDS="8, 234, 63, 251" HREF="wince/index.htm">
//    <AREA SHAPE="RECT" COORDS="8, 216, 96, 234" HREF="what_new.htm">
//    <AREA SHAPE="RECT" COORDS="8, 200, 47, 216" HREF="tips/index.htm">
//    <AREA SHAPE="RECT" COORDS="8, 167, 78, 200" HREF="techref/index.htm">
//    <AREA SHAPE="RECT" COORDS="8, 137, 86, 167" HREF="oo/index.htm">
//    <AREA SHAPE="RECT" COORDS="8, 106, 96, 137" HREF="swpm/index.htm">
//    <AREA SHAPE="RECT" COORDS="8, 89, 84, 106" HREF="databases/index.htm">
//    <AREA SHAPE="RECT" COORDS="8, 73, 79, 89" HREF="java/index.htm">
//    <AREA SHAPE="RECT" COORDS="8, 55, 89, 73" HREF="downloads/index.htm">
//    <AREA SHAPE="RECT" COORDS="8, 38, 94, 55" HREF="bibliography.htm">
//    <AREA SHAPE="RECT" COORDS="8, 20, 59, 38" HREF="COM/index.htm">
//    <AREA SHAPE="RECT" COORDS="8, 2, 72, 19" HREF="index.htm">
//    </MAP>
//    <a href="_vti_bin/shtml.exe/index.htm/map">
//    <img ismap usemap="#FrontPageMap" border="0" height="290" 
//    onmouseover="window.status='Main Menu'; return true;" 
//    alt="Main Menu" src="images/MainMenu2c.gif" width="130">
//    </a>
//    <!--webbot bot="ImageMap" endspan i-checksum="52271" -->
// End of Code

// First define the constructor for this Object

function MainMenuImageMap(strRelativePath)
{
	this.m_strRelativePath = strRelativePath;	// save the relative path
}	// MainMenuImageMap

// Links to other bits of the site
MainMenuImageMap.m_strLinks = ["wince/index.htm",
							"what_new.htm",
							"tips/index.htm",
							"techref/index.htm",
							"oo/index.htm",
							"swpm/index.htm",
							"databases/index.htm",
							"java/index.htm",
							"downloads/index.htm",
							"bibliography.htm",
							"COM/index.htm",
							"corba/index.htm",
							"index.htm"];

MainMenuImageMap.m_strTail = ["\">",
                              "\" width=\"130\">"];		// String tails
MainMenuImageMap.m_strImage = "images/MainMenu2e.gif";	// the image to display

MainMenuImageMap.m_strHTML = ["<MAP NAME=\"FrontPageMap\">",
    "<AREA SHAPE=\"RECT\" COORDS=\"6, 254, 63, 270\" HREF=\"",
    "<AREA SHAPE=\"RECT\" COORDS=\"6, 237, 100, 254\" HREF=\"",
    "<AREA SHAPE=\"RECT\" COORDS=\"6, 217, 64, 237\" HREF=\"",
    "<AREA SHAPE=\"RECT\" COORDS=\"6, 186, 80, 217\" HREF=\"",
    "<AREA SHAPE=\"RECT\" COORDS=\"6, 156, 100, 186\" HREF=\"",
    "<AREA SHAPE=\"RECT\" COORDS=\"6, 124, 99, 156\" HREF=\"",
    "<AREA SHAPE=\"RECT\" COORDS=\"6, 108, 96, 124\" HREF=\"",
    "<AREA SHAPE=\"RECT\" COORDS=\"6, 92, 84, 108\" HREF=\"",
    "<AREA SHAPE=\"RECT\" COORDS=\"6, 75, 94, 92\" HREF=\"",
    "<AREA SHAPE=\"RECT\" COORDS=\"6, 58, 89, 73\" HREF=\"",
    "<AREA SHAPE=\"RECT\" COORDS=\"6, 39, 100, 58\" HREF=\"",
    "<AREA SHAPE=\"RECT\" COORDS=\"6, 20, 59, 39\" HREF=\"",
    "<AREA SHAPE=\"RECT\" COORDS=\"6, 0, 72, 19\" HREF=\"",
    "</MAP>",
    "<a href=\"_vti_bin/shtml.exe/index.htm/map\">",
    "<img ismap usemap=\"#FrontPageMap\" border=\"0\" height=\"290\" onmouseover=\"window.status='Main Menu'; return true;\" ",
    "alt=\"Main Menu\" src=\"",
    "</a>"];

// display the image map
MainMenuImageMap.prototype.Display = function()
{
	var i;
	var strOutput;
	document.write(MainMenuImageMap.m_strHTML[0]);
	for(i = 1;i < 14;i++)
	{
		strOutput = MainMenuImageMap.m_strHTML[i] + this.m_strRelativePath + MainMenuImageMap.m_strLinks[i-1] + MainMenuImageMap.m_strTail[0];
		document.write(strOutput);
	}
	
	for(i = 14;i < MainMenuImageMap.m_strHTML.length;i++)
	{
		if(i == 17)
		{
			strOutput = MainMenuImageMap.m_strHTML[i] + this.m_strRelativePath + MainMenuImageMap.m_strImage + MainMenuImageMap.m_strTail[1];
			document.write(strOutput);
		}
		else
			document.write(MainMenuImageMap.m_strHTML[i]);
	}
}	// MainMenuImageMap


// Display the SiteMap Button
function SiteMapButton(strRelativePath)
{
	// Display the Sitemap Button
	var strOutput = "<a href=\"javascript:SiteMapDisplay('" + strRelativePath + "');\" OnMouseOver=\"window.status='Marin Site Map';return true;\" ><img src= \"" + strRelativePath + "images/sitemap.gif\" border=\"0\"></a>"; 
	document.write(strOutput);	

}	// MainMenuImageMap


var SiteMapWindow = null;
var d;

// call this function when the user clicks on the button - I hope
function SiteMapDisplay(strRelativePath)
{
	if(SiteMapWindow != null)
	{
		SiteMapWindow.close();	// close an exisiting window
	}
	
	SiteMapWindow = window.open("Title","TestName","menubar=false,status=false,height=435,width=220,left=5,top=20,dependent=\"no\"");
	d = SiteMapWindow.document;		// short hand
	
	d.write("<Html><head></head><title>Marin Site Map</Title>");
	d.write("<body>");

	d.write("<img src=\"" + strRelativePath + "images/stuck1.gif\" alt=\"Stuck?\" border=\"0\">");
	d.write("<object ID=\"MarinSiteMap\" < CLASSID=\"CLSID:8E3D1EA1-FFC4-11D3-B78C-00C04F674643\" width=200 CODEBASE=\"http://www.marin.clara.net/classes/sitemap.dll#version=1,0,1,1\">");
	d.write("<param name=\"CreateFromResource\" value=\"true\">");
	d.write("</object>");
	d.write("<img src=\"" + strRelativePath + "images/stuck1_logo.gif\" alt=\"Stuck?\" border=\"0\">");
	d.write("</body></Html>");
	d.close();
}

