Google MapsAPIv3を統合するためにgoMapjQueryプラグインを使用しています。マップを再描画したいときに問題が発生します。LatitudeとLongitudeを入力するための2つの入力ボックスがあり、goMap javascriptコードをトリガーするテキストリンクがあります...これを初めて呼び出すと、マップは正常にレンダリングされますが、Latitude/Longitudeの値を変更して同じコードを再度呼び出すとマップは新しい座標に再描画されません...私のコードは次のようになります
<input id="form_office_latitude" class="span4 office_latitude" type="text" name="office_latitude" value="">
<input id="form_office_longitude" class="span4 office_longitude" type="text" name="office_longitude" value="">
<a class="check-map" href="javascript:{};">Preveri zemljevid</a>
$('.check-map').live('click', function(){
$("#map_canvas").goMap({
maptype: 'ROADMAP',
zoom: 15,
markers: [{
icon: base_url+'assets/img/marker.png',
latitude: $('.office_latitude').val(),
longitude: $('.office_longitude').val(),
id: 'test',
html: {
content: 'Hello Word!',
popup: true
}
}],
hideByClick: false
});
});