// 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    -->
	
		 
		 // Amir Alim Khan Medressa
	var point = new GPoint(64.41561,39.77552);
	createMarker(point,"<div id=bubble><b>Amir Alim Khan Medressa</b><br><br></div>","Amir Alim Khan Medressa");
		 
		 // Bolo-Hauz Mosque and Minaret
	var point = new GPoint(64.407274,39.777796);
	createMarker(point,"<div id=bubble><b>Bolo-Hauz Mosque</b><br><br></div>","Bolo-Hauz Mosque");
		 
		 // Char Minar
	var point = new GPoint(64.427363,39.774893);
	createMarker(point,"<div id=bubble><a href='http://www.sacred-destinations.com/uzbekistan/bukhara-char-minar.htm'><img style='border-color:#666666' border='1' hspace='5' align='left' src='http://www.sacred-destinations.com/uzbekistan/images/thumbs/char-minar-cc-night-eulen.jpg'><b>Char Minar</b></a><br><br>Its name means &quot;four minarets,&quot; but this interesting little building with four dome-topped towers was actually a gatehouse of a medressa.</div>","Char Minar");
		 
		 // Chashma-Ayub Mausoleum
	var point = new GPoint(64.402392,39.778332);
	createMarker(point,"<div id=bubble><b>Chashma-Ayub Mausoleum</b><br><br></div>","Chashma-Ayub Mausoleum");
	
	 	 	 
		 // Ismail Samani Mausoleum
	var point = new GPoint(64.400568,39.77707);
	createMarker(point,"<div id=bubble><a href='http://www.sacred-destinations.com/uzbekistan/bukhara-ismail-samani-mausoleum.htm'><img style='border-color:#666666' border='1' hspace='5' align='left' src='http://www.sacred-destinations.com/uzbekistan/images/thumbs/ismael-samani-mausoleum-cc-amauri-aguiar.jpg'><b>Ismail Samani Mausoleum</b></a><br><br>This small, elegant 10th-century mausoleum is one of Bukhara's oldest monuments. Built for the founder of the Samanid dynasty, its delicate terracotta brickwork disguises 2m-thick walls that have never needed repair.</div>","Ismail Samani Mausoleum");
	
		 // Kalon Minaret
	var point = new GPoint(64.415267,39.775635);
	createMarker(point,"<div id=bubble><a href='http://www.sacred-destinations.com/uzbekistan/bukhara-kalon-minaret.htm'><img style='border-color:#666666' border='1' hspace='5' align='left' src='http://www.sacred-destinations.com/uzbekistan/images/thumbs/kalon-minaret-cc-night-eulen.jpg'><b>Kalon Minaret</b></a><br><br>he 12th-century brick Kalon Minaret is one of the most impressive monuments in Bukhara and can be climbed for fine views. </div>","Kalon Minaret");
	
		 // Kalon Mosque
	var point = new GPoint(64.414129,39.77594);
	createMarker(point,"<div id=bubble><a href='http://www.sacred-destinations.com/uzbekistan/bukhara-kalon-minaret.htm'><img style='border-color:#666666' border='1' hspace='5' align='left' src='http://www.sacred-destinations.com/uzbekistan/images/thumbs/kalon-minaret-cc-night-eulen.jpg'><b>Kalon Mosque</b></a><br><br>The 16th-century Kalon Mosque was built on the site of an earlier mosque destroyed by Genghis Khan. The congregational mosque can house 10,000 worshippers.</div>","Kalon Mosque");
		 
		 // Kukeldash Medressa
	var point = new GPoint(64.420974,39.773978);
	createMarker(point,"<div id=bubble><b>Kukeldash Medressa</b><br><br></div>","Kukeldash Medressa");
		 
		 // Maghoki-Attar Mosque
	var point = new GPoint(64.418362,39.773248);
	createMarker(point,"<div id=bubble><a href='http://www.sacred-destinations.com/uzbekistan/bukhara-maghoki-attar-mosque.htm'><img style='border-color:#666666' border='1' hspace='5' align='left' src='http://www.sacred-destinations.com/uzbekistan/images/thumbs/maghoki-attar-oldest-mosque-cc-rperlin83.jpg'><b>Maghoki-Attar Mosque</b></a><br><br>This 12th-century mosque is the oldest in Central Asia. It also has a long history of sacredness - remains of a Zoroastrian temple and a Buddhist temple have been found beneath it, and Jews once used it in the evenings.</div>","Maghoki-Attar Mosque");
	
		 
		 // Mir-i-Arab Medressa
	var point = new GPoint(64.415819,39.776101);
	createMarker(point,"<div id=bubble><a href='http://www.sacred-destinations.com/uzbekistan/bukhara-mir-i-arab-medressa.htm'><img style='border-color:#666666' border='1' hspace='5' align='left' src='http://www.sacred-destinations.com/uzbekistan/images/thumbs/mir-i-arab-from-minaret-cc-miles-78.jpg'><b>Mir-i-Arab Medressa</b></a><br><br>This impressive medressa with two blue domes stands opposite the Kalon Mosque. Founded in the 16th century, it was a working seminary until its closure in 1920. Stalin reopened it in 1944.</div>","Mir-i-Arab Medressa");
	
		 	 
		 // Synagogue - approx.
	var point = new GPoint(64.41561,39.768362);
	createMarker(point,"<div id=bubble><b>Synagogue</b><br><br></div>","Synagogue");
	
		 // Ulughbek Medressa
	var point = new GPoint(64.417466,39.776814);
	createMarker(point,"<div id=bubble><a href='http://www.sacred-destinations.com/uzbekistan/bukhara-ulughbek-medressa.htm'><img style='border-color:#666666' border='1' hspace='5' align='left' src='http://www.sacred-destinations.com/uzbekistan/images/thumbs/uleg-beg-madrassa2-cc-upyernoz.jpg'><b>Ulughbek Medressa</b></a><br><br>Built in 1417, this is central Asia's oldest medressa and the model for many others. The elegant structure is decorated with blue tiles.</div>","Ulughbek Medressa");
	
	
	// 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);

	 
		 // Ark
	var point = new GPoint(64.411018,39.777895);
	createMarker(point,"<div id=bubble><a href=''><img style='border-color:#666666' border='1' hspace='5' align='left' src=''><b></b></a><br><br></div>","");
	
		
	
	 // put the assembled sidebar_html contents into the sidebar div
    //document.getElementById("sidebar").innerHTML = sidebar_html;
    }

	//]]>