//<![CDATA[
//Bath
var icon = new GIcon();
icon.image = "/maps/mm_20_red.png";
icon.shadow = "/maps/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);

function createMarker(point,html) {
	var marker = new GMarker(point,icon);
	GEvent.addListener(marker, 'click', function(){marker.openInfoWindowHtml(html);});
	return marker;
}
function showMarker(marker){
	GEvent.trigger(marker,"click");
}
function OpenMarker(){
	get_string = document.location.search;
	Charindex = get_string.indexOf('=');
	if(Charindex != -1){
		MarkerName = get_string.substr(Charindex+1, get_string.length - Charindex+1);
		varResult = showMarker(eval(MarkerName));
	}
}

function initialize(){
	if (GBrowserIsCompatible()) {

		var map = new GMap2(document.getElementById("map"));
		map.addControl(new GLargeMapControl());
		map.addControl(new GMapTypeControl());
		map.setCenter(new GLatLng(51.380473,-2.356911),15);			
		
		var point = new GLatLng(51.381071,-2.359703);
		roman_baths = createMarker(point,'<a href=\'/movies-of-bath/the-roman-baths.htm\'><img src=\"images/thumbs/roman-baths.jpg\" alt=\"Roman Baths\" width=\"250\" height=\"188\" border=\"0\"></a><p><span class=\'v12\'><b>The Roman Baths</b><br><a href=\'movies-of-bath/the-roman-baths.htm\'>Virtual Tour outside the entrance<br>to the Roman Baths</a></span>');
		map.addOverlay(roman_baths);

		var point = new GLatLng(51.380687,-2.358544);
		sally_lunn = createMarker(point,'<a href=\'/bath-tourist-attractions.htm\'><img src=\"images/thumbs/sally-lunn.jpg\" alt=\"Sally Lunn&#145;s\" width=\"194\" height=\"400\" border=\"0\"></a><p><span class=\'v12\'><b>Sally Lunn&#145;s House</b><br><a href=\'/bath-tourist-attractions.htm\'>Bath Tourist Attractions</a><br><a href=\'http://www.sallylunns.co.uk\' target=\'_blank\'>www.sallylunns.co.uk</a></span>');
		map.addOverlay(sally_lunn);

		var point = new GLatLng(51.381459,-2.358735);
		bath_abbey = createMarker(point,'<a href=\'/movies-of-bath/bath-abbey.htm\'><img src=\"images/thumbs/bath-abbey.jpg\" alt=\"Bath Abbey\" width=\"300\" height=\"264\" border=\"0\"></a><p class=\'v12\'><b>Bath Abbey</b><br><a href=\'movies-of-bath/bath-abbey.htm\'>360 degree movie near Bath Abbey</a></p>');
		map.addOverlay(bath_abbey);

		var point = new GLatLng(51.384263,-2.363176);
		jane_austen = createMarker(point,'<a href=\'bath-tourist-attractions.htm#jane_austen_museum\'><img src=\"images/thumbs/jane-austen-centre.jpg\" alt=\"The Jane Austen Centre\" width=\"250\" height=\"339\" border=\"0\"></a><p class=\'v12\'><b>The Jane Austen Centre</b><br><a href="bath-tourist-attractions.htm#jane_austen_museum">More Information Here</a></p>');
		map.addOverlay(jane_austen);

		var point = new GLatLng(51.377769,-2.356983);
		bath_station = createMarker(point,'<a href=\'/hotels-in-bath/hotels-in-bath.htm\'><img src=\"images/thumbs/bath-spa-station.jpg\" alt=\"Bath Rail Station\" width=\"350\" height=\"107\" border=\"0\"></a><p><span class=\'v12\'><b>Bath Spa Railway Station</b><br><a href=\'/hotels-in-bath/hotels-in-bath.htm\'>Browse Hotels in Bath</a></span>');
		map.addOverlay(bath_station);

		var point = new GLatLng(51.382248,-2.355326);
		bath_rugby = createMarker(point,"<a href='http://www.bathrugby.com' target='_blank'><img src='images/thumbs/the-rec-bath.jpg' alt='Bath Rugby Ground' width='400' height='176' border='0'></a><p><span class='v12'><b>Bath Rugby Club</b><br>The Recreation Ground, Spring Gardens, Bath<br><a href='http://www.bathrugby.com' target='_blank'>www.bathrugby.com</a><br><a href='bandb-bath.html'>Bed & Breakfast\'s In Bath</a></span>");
		map.addOverlay(bath_rugby);

		var point = new GLatLng(51.380473,-2.330963);
		bath_university = createMarker(point,'<a href=\'http://www.bath.ac.uk\'><img src=\"images/thumbs/bath_university.jpg\" alt=\"Bath University\" width=\"160\" height=\"67\" border=\"0\"></a><p><span class=\'v12\'><b>Bath University</b><br><a href=\'http://www.bath.ac.uk/about/campustour\' target=\'_blank\'>360 Virtual Tour of Bath University</a></span>');
		map.addOverlay(bath_university);

		var point = new GLatLng(51.382998,-2.357785);
		pulteney_bridge = createMarker(point,'<a href=\'/movies-of-bath/the-pulteney-bridge-bath.htm\'><img src=\"images/thumbs/pulteney-bridge.jpg\" alt=\"The Pulteney Bridge\" width=\"359\" height=\"150\" border=\"0\"></a><p><span class=\'v12\'><b>The Pulteney Bridge</b><br><a href=\'/movies-of-bath/the-pulteney-bridge-bath.htm\'>360 degree virtual tour</a></span>');
		map.addOverlay(pulteney_bridge);

		var point = new GLatLng(51.418218,-2.406907);
		bath_races = createMarker(point,"<a href=\'/whats-on/bath-races\'><img src='images/thumbs/bath-races.gif' alt='Bath Races' width='186' height='119' border='0'></a><p class='v12'><b>Bath Racecourse</b><br>Lansdown, Bath BA1 9BU<br><a href='/whats-on/bath-races'>Bath Races and Fixtures</a></p>");
		map.addOverlay(bath_races);

		var point = new GLatLng(51.387055,-2.368251);
		royal_crescent = createMarker(point,'<a href=\'/movies-of-bath/the-royal-crescent.htm\'><img src=\"images/thumbs/royal-crescent.jpg\" alt=\"The Royal Crescent\" width=\"450\" height=\"105\" border=\"0\"></a><p><span class=\'v12\'><b>The Royal Crescent</b><br><a href=\'/movies-of-bath/the-royal-crescent.htm\'>360 degree virtual tour</a></span>');
		map.addOverlay(royal_crescent);

		var point = new GLatLng(51.385954,-2.364067);
		bath_circus = createMarker(point,'<a href=\'/movies-of-bath/the-circus-bath.htm\'><img src=\"images/thumbs/the-circus.jpg\" alt=\"The Grand Circus, Bath\" width=\"300\" height=\"197\" border=\"0\"></a><p><span class=\'v12\'><b>The Circus</b><br><a href=\'/movies-of-bath/the-circus-bath.htm\'>360 degree virtual tour</a></span>');
		map.addOverlay(bath_circus);

		var point = new GLatLng(51.386211,-2.362836);
		assembly_rooms = createMarker(point,'<a href=\'/bath-tourist-attractions.htm#bath_fashion_museum\'><img src=\"images/thumbs/the-ballroom.jpg\" alt=\"The Assembly Rooms\" width=\"250\" height=\"199\" border=\"0\"></a><p><span class=\'v12\'><b>The Assembly Rooms</b><br><a href=\"/bath-tourist-attractions.htm#bath_fashion_museum\">The Fashion Museum</a></span>');
		map.addOverlay(assembly_rooms);

		var point = new GLatLng(51.381072,-2.358719);
		tourist_info = createMarker(point,'<a href=\'/movies-of-bath/bath-abbey.htm\'><img src=\"images/thumbs/tourist-info.jpg\" alt=\"Tourist Information Office\" width=\"300\" height=\"225\" border=\"0\"></a><p><span class=\'v12\'><b>Bath Tourist Information Office</b><br><a href=\'/movies-of-bath/bath-abbey.htm\'>360 Virtual Tour</a><br><a href=\'/hotels-in-bath/hotels-in-bath.htm\'>Staying in Bath? Hotels in Bath Here</a></span>');
		map.addOverlay(tourist_info);

		var point = new GLatLng(51.380681,-2.361111);
		spa = createMarker(point,'<a href=\'/movies-of-bath/bath-therm-spa-bath.htm\'><img src=\"panoramas/aqua-therme-thumb.jpg\" alt=\"Bath Thermae Spa\" width=\"530\" height=\"172\" border=\"0\"></a><p class=\'v12\'><b>Thermae Spa & Bath Street</b> - <a href=\'/movies-of-bath/bath-therm-spa-bath.htm\'>View our 360° movie</a></p>');
		map.addOverlay(spa);

		var point = new GLatLng(51.38438,-2.354698);
		pulteney_st = createMarker(point,'<a href=\'movies-of-bath/great-pulteney-street-bath.htm\'><img src=\"../panoramas/pulteney-bridge-thumb.jpg\" alt=\"Great Pulteney Street Bath\" width=\"530\" height=\"172\" border=\"0\"></a><p class=\'v12\'><b>Great Pulteney Street</b> - <a href=\'movies-of-bath/great-pulteney-street-bath.htm\'>View our 360° movie</a></p>');
		map.addOverlay(pulteney_st);

		var point = new GLatLng(51.386786,-2.360258);
		museum = createMarker(point,'<p class=\'v12\'><b>The Building of Bath Museum</b><br>The Countess of Huntingdon’s Chapel<br>The Vineyards, The Paragon<br>Bath BA1 5NA<br><a href=\'bath-tourist-attractions.htm#building_bath\'>More Info</a></p>');
		map.addOverlay(museum);

		var point = new GLatLng(51.387356,-2.373884);
		victoria_park = createMarker(point,"<img src='panoramas/park-thumb.jpg' width='530' height='172' alt='Royal Victoria Park Bath'><p class='v12'><b>Royal Victoria Park</b> - Home of the <a href='whats-on-in-bath'>Bath Spring Flower Show</a></p>");
		map.addOverlay(victoria_park);

		var point = new GLatLng(51.368485,-2.345012);
		prior_park = createMarker(point,"<div class='v12'><b>Prior Park</b> - 18th Century Landscape Garden</div>");
		map.addOverlay(prior_park);

		var point = new GLatLng(51.382797,-2.35841);
		art_gallery = createMarker(point,"<div class='v12'><img src='whats-on/images/victoria-art-gallery-bath.jpg' width='250' height='418' alt='Victoria Art Gallery Bath'><p><b>Victoria Art Gallery</b> - Free public gallery<br><a href='http://www.victoriagal.org.uk' target='_blank'>www.victoriagal.org.uk</a></div>");
		map.addOverlay(art_gallery);
		
		var point = new GLatLng(51.388857,-2.35889);
		nick = createMarker(point,"<div class='v12'><img src='maps/artist-nick-cudworth.jpg' alt='Nick Cudworth Art Gallery Bath' width='200' height='273'><p><b>Nick Cudworth Gallery</b><br>5 London Street, Bath BA1 5BU<br><a href='whats-on/nick-cudworth-gallery' title='Nick Cudworth Gallery'>more..</a></div>");
		map.addOverlay(nick);
		

		OpenMarker();


	}else{
		alert("Sorry your browser is not compatible with our google map");
	}
}

//]]>
