<script type="text/javascript">
var markers = [
{
"title": 'Griffith Park',
"lat": '34.1365588',
"lng": '-118.2963887',
"description": '<p><b>Griffith Park</b> is the tenth-largest municipally owned park in the United States and one of the largest urban parks in North America, spanning over 4,300 acres of land.<p>'+ '<img src="images/gp.jpg" style="width: 100%">'
},
{
"title": 'Golden Gate Park',
"lat": '37.7577944',
"lng": '-122.5071063',
"description": '<p><b>Golden Gate Park</b>, located in San Francisco, California, United States, is a large urban park consisting of 1,017 acres (412 ha) of public grounds.</p>'+ '<img src="images/ggp.jpg" style="width: 100%">'
},
{
"title": 'Central Park',
"lat": '40.7828647',
"lng": '-73.9675438',
"description": '<p><b>Central Park</b> is an urban park in middle-upper Manhattan, within New York City. Central Park is the most visited urban park in the United States, with 40 million visitors in 2013.</p>' +'<img src="images/centralpark.jpg" style="width: 100%">'
},
{
"title": 'Rock Creek Park',
"lat": '38.9552176',
"lng": '-77.0492686',
"description": '<p><b>Rock Creek Park</b> is a large urban park that bisects the Northwest quadrant of Washington, D.C. The park was created by an Act of Congress in 1890.</p>' + '<img src="images/wa.jpg" style="width: 100%">'
},
{
"title": 'Lake Mead National Recreation Area',
"lat": '36.0973362',
"lng": '-114.4272836',
"description": '<p><b>Lake Mead National Recreation Area</b> is a U.S. National Recreation Area located in southeastern Nevada and northwestern Arizona.</p>' +'<img src="images/lake.jpg" style="width: 100%">'
}
];
window.onload = function () {
LoadMap();
}
function LoadMap() {
var center = {lat: 41.850033, lng: -87.6500523};
var mapOptions = {
center: center,
zoom: 3,
mapTypeId: google.maps.MapTypeId.ROADMAP
};
var map = new google.maps.Map(document.getElementById("dvMap"), mapOptions);
var infoWindow = new google.maps.InfoWindow();
for (var i = 0; i < markers.length; i++) {
var data = markers[i];
var myLatlng = new google.maps.LatLng(data.lat, data.lng);
var marker = new google.maps.Marker({
position: myLatlng,
map: map,
icon: iconBase + 'info_maps.png',
title: data.title
});
(function (marker, data) {
google.maps.event.addListener(marker, "click", function (e) {
infoWindow.setContent("<div style = 'width:200px;min-height:150px'>" + data.description + "</div>");
infoWindow.open(map, marker);
});
})(marker, data);
}
}
</script>