
function isIE4()
{
	if (document.layers)
		return false;
	else
		return true;
}

function writeBar(nIndex, appletText)
{	
	var at = "";
	at = at + appletText;	

	document.write("<style>A.am { color: white; text-decoration:none; } A.am:hover { text-decoration: underline; }</style>");
	
	var htmlStr = "<table border=0 width=750 cellpadding=0 cellspacing=0><tr>";
	
	if (isIE4() == true)	//Internet Explorer
	{
		htmlStr = htmlStr + "<td width=537 background=line.gif height=50><table cellpadding=0 cellspacing=0 width=100%><tr><td align=right>";
		
		htmlStr = htmlStr + '<img src="bar.gif" usemap="#Map" border="0"><map name="Map"><area shape="rect" coords="2,2,36,15" href="default.asp"><area shape="rect" coords="47,1,120,17" href="newrel.asp"><area shape="rect" coords="132,4,182,14" href="aboutus.asp"><area shape="rect" coords="190,2,234,15" href="contact.asp"><area shape="rect" coords="240,2,275,15" href="views.asp"><area shape="rect" coords="287,2,377,16" href="manu.asp"><area shape="rect" coords="389,4,446,15" href="guestbk.asp"></map>';
			
		var i=0;
		for (i=0; i<4; i++)
			htmlStr = htmlStr + "&nbsp;";
		
		htmlStr = htmlStr + "</font><img align=top src=mt.jpg></td></tr><tr><td height=28 align=right>";
		if (at != "undefined")
		{
			htmlStr = htmlStr + "<applet code=NewsScroller.class width=533 height=28><param name=news value='";
			htmlStr = htmlStr + at + "'></applet>";
		}
		else
		{
			if (nIndex == 1)
				htmlStr = htmlStr + "<img src=newrel.gif align=top>";
			if (nIndex == 2)
				htmlStr = htmlStr + "<img src=aboutus.gif align=top>";
			if (nIndex == 3)
				htmlStr = htmlStr + "<img src=contact.gif align=top>";
			if (nIndex == 4)
				htmlStr = htmlStr + "<img src=views.gif align=top>";
			if (nIndex == 5)
				htmlStr = htmlStr + "<img src=search.gif align=top>";
			if (nIndex == 6)
				htmlStr = htmlStr + "<img src=models.gif align=top>";
			if (nIndex == 7)
				htmlStr = htmlStr + "<img src=gb.gif align=top>";

			htmlStr = htmlStr + "<img src=spacerw.gif width=275 height=20><img align=top src=mb.gif>";
		}
		
		htmlStr = htmlStr + "</td></tr></table></td><td width=213><img height=50 width=213 src=main.jpg></td>";
		
		document.writeln(htmlStr);
	}
	
	else			//Netscape
	{
		htmlStr = htmlStr + "<td valign=top width=537 height=50 background='bg-net.jpg'>";
		
		htmlStr = htmlStr + '<img src="bar.gif" usemap="#Map" border="0"><map name="Map"><area shape="rect" coords="2,2,36,15" href="default.asp"><area shape="rect" coords="47,1,120,17" href="newrel.asp"><area shape="rect" coords="132,4,182,14" href="aboutus.asp"><area shape="rect" coords="190,2,234,15" href="contact.asp"><area shape="rect" coords="240,2,275,15" href="views.asp"><area shape="rect" coords="287,2,377,16" href="manu.asp"><area shape="rect" coords="389,4,446,15" href="guestbk.asp"></map>';
			
		if (nIndex == 1)
			htmlStr = htmlStr + "<img src=newrel.gif align=top>";
		if (nIndex == 2)
			htmlStr = htmlStr + "<img src=aboutus.gif align=top>";
		if (nIndex == 3)
			htmlStr = htmlStr + "<img src=contact.gif align=top>";
		if (nIndex == 4)
			htmlStr = htmlStr + "<img src=views.gif align=top>";
		if (nIndex == 5)
			htmlStr = htmlStr + "<img src=search.gif align=top>";
		if (nIndex == 6)
			htmlStr = htmlStr + "<img src=models.gif align=top>";
		
		htmlStr = htmlStr + "</font></td><td width=213 height=50><img border=0 src=main.jpg width=213 height=50></td></tr></table>";
				
		document.write(htmlStr);
	}
}
