Created
March 19, 2013 01:44
-
-
Save ss23/5192974 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var map; | |
jQuery(document).ready(function() { | |
var mapOptions = { | |
center: new google.maps.LatLng(-37.522797, 175.567017), | |
zoom: 6, | |
mapTypeId: google.maps.MapTypeId.ROADMAP | |
}; | |
map = new google.maps.Map(document.getElementById("map-select"), mapOptions); | |
/* | |
jQuery('#map-select').parents('form').submit(function() { | |
newOptions = {}; | |
newOptions.zoom = map.zoom; | |
newOptions.center = {}; | |
newOptions.center.lat = map.center.mb; | |
newOptions.center.lng = map.center.nb; | |
console.log(newOptions); | |
//jQuery("[name=MapOptions]").val(JSON.stringify(newOptions)); | |
}); | |
*/ | |
/* | |
jQuery("#add-marker").click(function() { | |
console.log('clicked'); | |
marker = new google.maps.Marker({ | |
position: map.center, | |
map: map, | |
draggable: true | |
}); | |
}); */ | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment