// Java Document

 //<![CDATA[
 
 // Begin Javascript
var gmarkers = [];
var htmls = [];
function myclick(i) {
gmarkers[i].openInfoWindowHtml(htmls[i]);
}
    function onLoad() {
      // Map Overlays
      //
      
	  // This function picks up the click and opens the corresponding info window
// Creates one a small marker at the given point
function createMarker(point, attributeHTMLString, name) {
  var marker = new GMarker(point, icon);
  map.addOverlay(marker);
  GEvent.addListener(marker, "click", function() {
    marker.openInfoWindowHtml(attributeHTMLString);
  });
  // save the info we need to use later for the sidebar
  gmarkers[i] = marker;
  htmls[i] = attributeHTMLString;
  // add a line to the sidebar html
  sidebar_html += '<a href="javascript:myclick(' + i + ')">' + name + '</a><br>';
        i++;
        return marker;
}



      // Create small marker icon
var icon = new GIcon();
icon.image = "http://labs.google.com/ridefinder/images/mm_20_blue.png";
icon.shadow = "http://labs.google.com/ridefinder/images/mm_20_shadow.png";
icon.iconSize = new GSize(12, 20);
icon.shadowSize = new GSize(22, 20);
icon.iconAnchor = new GPoint(6, 20);
icon.infoWindowAnchor = new GPoint(5, 1);

<!--    begin pulling data    -->
	
	 
		 
		 // Basilica of the Annunciation
	var point = new GPoint(35.29749,32.702149);
	createMarker(point,"<div id=bubble><a href='http://www.sacred-destinations.com/israel/nazareth-basilica-of-annunciation.htm'><img style='border-color:#666666' border='1' hspace='5' align='left' src=''><b>Basilica of the Annunciation</b></a><br><br>Completed in 1969, this Catholic basilica stands on the traditional site where the angel Gabriel announced to Mary that she would bear the Savior. It is built over Crusader and Byzantine foundations.</div>","");
		
	 
		 // Church of St. Gabriel
	var point = new GPoint(35.301587,32.707057);
	createMarker(point,"<div id=bubble><a href='http://www.sacred-destinations.com/israel/nazareth-st-gabriel-orthodox-church.htm'><b>Church of St. Gabriel</b></a><br><br>Orthodox Christians believe that the Annunciation occurred not at Mary's house but while she was fetching water. Therefore this 17th-century Orthodox church is built over the spring that feeds Mary's Well.</div>","");
	 
	// Church of St. Joseph
	var point = new GPoint(35.298346, 32.703184);
	createMarker(point,"<div id=bubble><b>Church of St. Joseph</b><br><br>A Catholic church on the traditional site of Joseph's carpentry shop.</div>","");
	
		 // Mary's Well
	var point = new GPoint(35.3014675,32.70628);
	createMarker(point,"<div id=bubble><a href=''><img style='border-color:#666666' border='1' hspace='5' align='left' src='http://www.sacred-destinations.com/israel/images/thumbnails50/nazareth-marys-spring-wp-pd.jpg'><b>Mary's Well</b></a><br><br>This well is traditionally believed to be the place from which Mary and the young Jesus drew water when they lived nearby. The structure built over it dates from the 19th century.</div>","");
	
	// Synagogue Church
	var point = new GPoint(35.296127, 32.703649);
	createMarker(point,"<div id=bubble><b>Synagogue Church</b><br><br>A church built over the traditional site of the synagogue where Jesus worshiped and preached as a young man.</div>","");
	
	
	// Create small marker icon
var icon = new GIcon();
icon.image = "http://labs.google.com/ridefinder/images/mm_20_white.png";
icon.shadow = "http://labs.google.com/ridefinder/images/mm_20_shadow.png";
icon.iconSize = new GSize(12, 20);
icon.shadowSize = new GSize(22, 20);
icon.iconAnchor = new GPoint(6, 20);
icon.infoWindowAnchor = new GPoint(5, 1);


		
	
	 // put the assembled sidebar_html contents into the sidebar div
    //document.getElementById("sidebar").innerHTML = sidebar_html;
    }

	//]]>