1
我有这个代码在谷歌地图在我的网页..我想改变经度和纬度的值..它应该从我的数据库..我将如何实现它?使用zend框架将数据从数据库传递给jquery
$(function() {
demo.add(function() {
$('#gmap').gmap({'center': '47.660937,9.569803', 'zoom': 10,'disableDefaultUI':true, 'callback': function() {
var self = this;
self.addMarker({'position': this.get('map').getCenter() }).click(function() {});
}});
}).load();
});
这里的时候,我怎么申报从数据库中我的变量..
$propertyId = $this->_getParam('propertyId', null);
$propDetail = $propertyDb->getProperty($sessionOutlet, $propertyId);
$this->view->description = $propDetail[0]['Description'];
$this->view->propertyname = $propDetail[0]['PropertyName'];
$this->view->longitude = $propDetail[0]['Longitude'];
$this->view->latitude = $propDetail[0]['Latitude'];