<!--
  var htmlOpener = "<html><head><title>2003 Proposed Budget Graph</title></head><img src=";
  var htmlCloser = "></body></html>";
  var popupWin;
  var wholeWin;
  var steps = 18;
  var split = 15;
  var rsteps = 40;
  var menuitems =[ [ "http://www.yorkcity.org/pubsafety/police/index.htm", "Police", "http://www.yorkcity.org/pubsafety/fire/index.htm", "Fire", "http://www.yorkcity.org/cityservices/parking/index.htm", "City Parking", "http://www.yorkcity.org/pubsafety/health/index.htm", "Health", "http://www.yorkcity.org/comaffairs/index.htm","Community Development", "http://www.yorkcityevents.org","Upcoming Events","http://www.yorkcity.org/cityservices/permits/permit.htm","Permits","http://www.yorkcity.org/cityservices/sewerrefuse/index.htm","Sewer/Refuse/Yard Waste", "http://www.yorkcity.org/cityservices/wwtp/index.htm","Waste Water Treatment Plant", "http://www.yorkskate.com", "York City Ice Arena", "http://www.yorkcity.org/residents/FinDocs/FinancialReports.htm","Financial Statements"],
				  ["http://www.yorkcity.org/visitors/walkingtour/index.htm", "Walking Tour","http://www.yorkcity.org/econ/murals/index.htm", "Murals","http://www.yorkcity.org/visitors/railtrail/index.htm", "Rail Trail", "http://www.yorkcity.org/visitors/visitorcntr/index.htm", "Visitor Center", "http://www.yorkcity.org/visitors/accom/index.htm", "Accommodations", "http://www.yorkcity.org/cityservices/parking/index.htm", "City Parking", "http://www.yorkcity.org/visitors/arts/index.htm", "Arts & Culture", "http://www.yorkcity.org/visitors/attractions/index.htm", "Attractions", "http://www.yorkcity.org/visitors/dinning/index.htm", "Dining & Shopping", "http://www.yorkcity.org/history/index.htm", "York City History", "http://www.yorkcity.org/visitors/visitorcntr/directionstocity.htm", "Driving Directions"], 
				  ["http://www.yorkcity.org/econ/starting.htm", "Getting Started", "http://www.yorkcity.org/econ/index.htm", "Economic Development", "http://www.yorkcity.org/econ/koz/index.htm", "KOZ Opportunities", "http://www.yorkcity.org/econ/comaffairs/permit/harb.html", "HARB", "http://www.yorkcity.org/cityservices/permits/permit.htm", "Permits and Health Licensing", "http://www.yorkcity.org/econ/4Keys/index.htm", "Spurring Economic Development"] ]

function generate_layers()
{ 
  var x=0; 
  browser_type = navigator.appName;
 
  for (x=0; x< menuitems.length; x++) 
	  { 
		if (browser_type ==  "Microsoft Internet Explorer") { 
		document.writeln ('<div id=submenu'+ (x+1)  +' name=submenu'+ (x+1)  +' class=submenuStyle style="z-index:100;">');
		}
		else {
		document.writeln ('<div id=submenu'+ (x+1)  +' name=submenu'+ (x+1)  +' class=submenuStyle style="z-index:100;" >');
		}		
		document.writeln ('<table border=1 bgcolor=#FFFFFF bordercolor=#003366 cellspacing=0 cellpadding=5><tr><td valign=top>')
		 var intmaxsplit = 50
			if ((menuitems[x].length/4) > (split/2)) { 
			var intmaxsplit = (menuitems[x].length/2) 
			if  (((intmaxsplit) % 2) == 0.5) {var intmaxsplit = intmaxsplit + 1;} 
			}
		  for (xx=0; xx< menuitems[x].length; xx++) 
		  { 
			if (browser_type ==  "Microsoft Internet Explorer") {
			document.writeln ('<TABLE width=175 border=0 cellspacing=0 cellpadding=0><TR>')
			document.writeln ('<TD style=width:100%;')
			document.writeln ('onMouseover="this.style.backgroundColor=\'#FFFF99\';window.status=\' '+ menuitems[x][xx+1] +' \';return true;"')
			document.writeln ('onMouseout="this.style.backgroundColor=\'\';window.status=\'\';return true;">')
			document.writeln ('<a  href = ' + menuitems[x][xx] + ' class=m >');
			document.writeln ('' + menuitems[x][xx+1] + ' </a><br>');
			document.writeln ('</TD></TR></TABLE>'); 
			}
			else {
			document.writeln ('<a  href = ' + menuitems[x][xx] + ' class=m >');
			document.writeln ('' + menuitems[x][xx+1] + '</a><br>');
			}
		   xx = xx +1
		    if ((xx) > intmaxsplit - 2) { document.writeln('</td><td valign=top>') 
		    var intmaxsplit = 500
		    }   
		  }
		document.writeln ('<br>'); 
		document.writeln ('</td></tr></table></div>');  
		  } 
	 }
generate_layers();

if (browser_type == "Netscape" && (browser_version >= 4) && navigator.platform.indexOf("Mac") >= 0) { var steps = steps - 20 }

function getAnchorPosition(anchorname) {
	var useWindow = false;
	var coordinates = new Object();
	var x=0;
	var y=0;
	var w_gebi = false;
	var w_css = false;
	var w_layers = false;
	if (document.getElementById) { w_gebi = true; }
	else if (document.all) { w_css = true; }
	else if (document.layers) { w_layers = true; }

 	if (w_gebi && document.all) {
		x = AnchorPosition_getPageOffsetLeft(document.all[anchorname]);
		y = AnchorPosition_getPageOffsetTop(document.all[anchorname]);
		}
	else if (w_gebi) {
		var o = document.getElementById(anchorname);
		x = o.offsetLeft;
		y = o.offsetTop;
		}
 	else if (w_css) {
		x = AnchorPosition_getPageOffsetLeft(document.all[anchorname]);
		y = AnchorPosition_getPageOffsetTop(document.all[anchorname]);
		}
	else if (w_layers) {
		var found=0;
		for (var i=0; i<document.anchors.length; i++) {
			if (document.anchors[i].name == anchorname) {
				found=1;
				break;
				}
			}
		if (found == 0) {
			coordinates.x=0; coordinates.y=0; return coordinates;
			}
		x = document.anchors[i].x;
		y = document.anchors[i].y;
		}
	else {
		coordinates.x=0; coordinates.y=0; return coordinates;
		}
	coordinates.x = x;
	coordinates.y = y;
	return coordinates;
	}


function AnchorPosition_getPageOffsetLeft (el) {
	var ol = el.offsetLeft;
	while ((el = el.offsetParent) != null) { 
		ol += el.offsetLeft; 
		}
	return ol;
	}
function AnchorPosition_getWindowOffsetLeft (el) {
	var scrollamount = document.body.scrollLeft;
	return AnchorPosition_getPageOffsetLeft(el)-scrollamount;
	}	
function AnchorPosition_getPageOffsetTop (el) {
	var ot = el.offsetTop;
	while((el = el.offsetParent) != null) { 
		ot += el.offsetTop; 
		}
	return ot;
	}

function AnchorPosition_getWindowOffsetTop (el) {
	var scrollamount = document.body.scrollTop;
	return AnchorPosition_getPageOffsetTop(el)-scrollamount;
	}

function removeall() {
	for(i = 1; i <= menuitems.length; i++) { remove(i);  }
}


function show(object) {

	var c = getAnchorPosition(object.replace(/submenu/, "menu"));
	if (c.x < 1) { c.x = 21; }
	if (c.y < 1) { c.y = 155; }
	
    if (document.getElementById && document.getElementById(object) != null) {
        document.getElementById(object).style.top=c.y + steps+"px";
        document.getElementById(object).style.left= c.x - rsteps+"px";
        node = document.getElementById(object).style.visibility='visible';
        document.body.onclick= removeall;
    }
    else if (document.layers && document.layers[object] != null) {
		 document.layers[object].visibility = 'visible';
		 document.layers[object].top = c.y + steps;
		 document.layers[object].left = c.x - rsteps;
		 document.captureEvents(Event.MOUSEMOVE | Event.MOUSEDOWN);
		 document.onmousedown = removeall;
		 }
    else if (document.all) 
	  {
        document.all[object].style.visibility = 'visible';
        document.all[object].style.pixelTop = c.y + steps;
		document.all[object].style.pixelLeft = c.x - rsteps;
		document.body.onclick= removeall;
		}

	var id = object.replace(/submenu/, "");
	for(i = 1; i <= menuitems.length; i++)
	{
		if  (i != id) {
		remove(i);
		}
	}
	var c = null
}

function removeall() {
	for(i = 1; i <= menuitems.length; i++) { remove(i);  }
}

function remove(id) {
    
      if (document.getElementById && document.getElementById('submenu'+id) != null) {
        node = document.getElementById('submenu'+id).style.visibility='hidden';
    }
    else if (document.layers && document.layers['submenu'+id] != null) {
		 document.layers['submenu'+id].visibility = 'hidden';
		 }
    else if (document.all) 
	  {
        document.all['submenu'+id].style.visibility = 'hidden';
		}
}

function openWindow(url, help) {
	popupWin = window.open(url, help, "width=588,height=564,top=5,left=100,alwaysRaised=yes,toolbar=0,directories=0,menubar=0,status=1,resizable=no,location=0,scrollbars=1,copyhistory=0");
}

function openCard(url, help) {
	popupWin = window.open(url, help, "width=200,height=350,top=5,left=100,alwaysRaised=yes,toolbar=0,directories=0,menubar=0,status=1,resizable=no,location=0,scrollbars=1,copyhistory=0");
}


function popup(term)  // write corresponding content to the popup window
  {
   popupWin = window.open("", "puWin",  "width=600,height=500,scrollbars,dependent,resizable");
   popupWin.document.open("text/html", "replace"); 
   popupWin.document.write(htmlOpener);
   popupWin.document.write(term);
   popupWin.document.write(htmlCloser);
   popupWin.document.close();  // close layout stream
   popupWin.focus();  // bring the popup window to the front
  }

function closeDep() {
  if (popupWin && popupWin.open && !popupWin.closed) popupWin.close();
  if (wholeWin && wholeWin.open && !wholeWin.closed) wholeWin.close();

  }

function Xprint(Label)
   {
   text1.value=Label
   }

//-->

