 //<![CDATA[
        var dirAddress, fullAddress, addressArray;
        var name;
		var addText = "http://maps.google.com/maps?f=d&hl=en&saddr=&daddr=";
		//var addText = "http://maps.google.com/maps?q="
		//addText += fullAddress
        
		function HideContent(d) {		
			$('light').style.display = 'none';
			resizeOverlay();
		}
		function ShowContent(d) {
			$('black_overlay').style.height = '1900px'; 
			$('light').style.display = 'block';
			$('light').style.visibility = 'visible';
		}
		function ReverseDisplay(d) {
			if(document.getElementById(d).style.visibility == "hidden") {
				document.getElementById(d).style.visibility = "visible";
			} else {
				document.getElementById(d).style.visibility = "hidden";
			}
		}
		function resizeOverlay() {
			var PageSize = getPageSizeWithScroll();
			if(PageSize[1] < screen.height) PageSize[1] = screen.height; // use a minimum of screen height, sometimes content is
			$('light').style.height = PageSize[1] + 'px';
		}
		function getPageSizeWithScroll(){
			if (window.innerHeight && window.scrollMaxY) {// Firefox
				yWithScroll = window.innerHeight + window.scrollMaxY;
				xWithScroll = window.innerWidth + window.scrollMaxX;
			} else if (document.body.scrollHeight > document.body.offsetHeight) { // all but Explorer Mac
				yWithScroll = document.body.scrollHeight;
				xWithScroll = document.body.scrollWidth;
			} else { // works in Explorer 6 Strict, Mozilla (not FF) and Safari
				yWithScroll = document.body.offsetHeight;
				xWithScroll = document.body.offsetWidth;
			}
			arrayPageSizeWithScroll = new Array(xWithScroll,yWithScroll);
			return arrayPageSizeWithScroll;
		}
		
		// On page load, call this function
		function load()
		{
			var geocoder;
			var map;
			
			
			/*_____________________
				Weather Module		
			_____________________*/
			
			var mapWeatherMod = document.getElementById('mapWeatherMod');
			//	test URL >>> var weatherURL = 'http://teg8fref1:8080/weather/pForecast.jsp?zipCode='+zip;

			var weatherURL = 'http://weather.cnn.com/weather/pForecast.jsp?zipCode='+zip;
			mapWeatherMod.innerHTML = '<iframe id="weatherframe" frameborder="0" scrolling="no" allowtransparency="false" backgroundColor="#e2e2e2" src="'+ weatherURL +'"></iframe>';
			
			/*_____________________
				END: Weather Module		
			_____________________*/
								
			// Create new map object
			map = new GMap2(document.getElementById("map"));
			map.addControl(new GLargeMapControl());
			
			// Create new geocoding object
			geocoder = new GClientGeocoder();
			
			// Retrieve location information, pass it to addToMap()
			geocoder.getLocations(dirAddress, addToMap);
			
			// This function adds the point to the map
			function addToMap(response)
			{
				console.log(response);
				addressArray = dirAddress.split(',');
				var streetAddr = addressArray[0];
				var cityAddr = addressArray[1];
				var stateAddr = addressArray[2];
				var zipAddr = addressArray[3];
		
				var locations_div = document.getElementById('mapDetailMod');
				locations_div.innerHTML = '';
				//locations_div.innerHTML += "Location Name";

				//Added by Brad
				locations_div.innerHTML += '<p class="course"><a href="javascript:clickMap()"><span class="courseN">'+name+'</span></a><br><span class="greyOut">'+streetAddr+'<br/>'+cityAddr+', '+stateAddr+' '+zipAddr+'</span><br/><span class="goldBold"><a href="'+addText+fullAddress+'" target="_blank" style="color:#89761A;">get directions</a></span></p>';
				
      			// Retrieve the object
     	 		place = response.Placemark[0];
      
				// Retrieve the latitude and longitude
      			point = new GLatLng(place.Point.coordinates[1],
                place.Point.coordinates[0]);

      			// Center the map on this point
      			map.setCenter(point, 10);
      			
				// Create a marker
      			marker = new GMarker(point);

      			// Add the marker to map
      			map.addOverlay(marker);
      
      			// Add address information to marker
        		marker.openInfoWindowHtml(name + '<br />' + '<span>'+streetAddr+'<br/>'+cityAddr+', '+stateAddr+' '+zipAddr+'</span>');
      
       			GEvent.addListener(marker, "click", function() {
        			marker.openInfoWindowHtml(name + '<br />' + dirAddress);
      			});
				//map.panTo(point);

			}
			findPos();
		}
		function clickMap() {
        	GEvent.trigger(marker, "click");
      	}
	function doTip(num) {
		var tipStr = "";
		switch (num) {
			case 1 : tipStr = "This facility accepts used golf cub trade-ins.";
			default: break;
		}
		Tip(tipStr);
		return;
	}		
    //]]>