Reputation: 1216
hi there this code works for me.
setMap("France",5);
function setMap(iaddress,izoom){
$("#test").gmap3({
marker:{
address: iaddress
},
map:{
options:{
zoom: izoom
}
}
});
}
the map will zoom in 5 on france country.
but when run it again with this jquery code:
function checkCitySelect(){
$("#test2").on('click', function() {
setMap("Recklinghausen",14);
});
}
it works but "Recklinghausen" is not center of google map! the center is somewhere in France(the center is last address but zoom works)
for example If I go to "Recklinghausen" manualy. that location marked.
how can go automaticly to "Recklinghausen" when I update map?
Upvotes: 0
Views: 200