приветствия и приветствия,
это мой первый запуск с API Google Maps, я использую WordPress и Genesis Framework,
Я работаю над учебником по http://tympanus.net/codrops/2011/04/13/interactive-google-map/
, и я получил карту Google, которая будет отображаться на странице карты,
http://www.foodtrucksnashville.com/map/
однако вы заметите, что элементы управления картой находятся подкарта.хммм.
понятия не имею.нужна помощь / толчок в правильном направлении.
спасибо еще раз, сообщество stackoverflow.
вот код в init.js:
var map, geocoder, marker, ey, my, mouseDown = false;
var o = {
init: function () {
this.map.init();
},
map: {
size: function () {
// so it's a loverly sqware.
var w = jQuery('.content-sidebar #content').width(),
h = 440;
return {
width: w,
height: h
}
},
data: {
zoom: 13,
center: new google.maps.LatLng(36.165389, -86.783237), // Nashville TN Capitol BLDG
scrollwheel: false,
mapTypeId: google.maps.MapTypeId.ROADMAP
},
init: function () {
// get the map size
var size = o.map.size();
// add some css to the #map div based on the size
jQuery('#map').css({
width: size.width,
height: size.height,
});
// make a new google map in the #map div and pass it the map data
map = new google.maps.Map(document.getElementById('map'), o.map.data), geocoder = new google.maps.Geocoder();
/*
// add eventlistener to map to hide posts when dragging?
google.maps.event.addListener(map, 'dragstart', function () {
jQuery('.posts').hide();
});
*/
}
} // end map
} // end o object
jQuery(window).load(function () {
o.init();
});