Php 如何使用CodeIgniter库显示多个标记Google Maps
我有一个关于旅游和旅游的web应用程序,在我的网站上我有一个使用Google Maps API V3的地图。我正在使用CodeIgniter开发我的网站,并使用biostall.com上的谷歌地图库显示谷歌地图API V3 Iam 我创建此链接以显示多个标记: 但我不知道如何显示数据库MySQL中的所有标记,因为我是CI新手,仍然对MVC概念感到困惑:) 我的桌子是destinasi,即结构: id int 长双人 拉特双人床Php 如何使用CodeIgniter库显示多个标记Google Maps,php,codeigniter,google-maps,google-maps-api-3,google-maps-markers,Php,Codeigniter,Google Maps,Google Maps Api 3,Google Maps Markers,我有一个关于旅游和旅游的web应用程序,在我的网站上我有一个使用Google Maps API V3的地图。我正在使用CodeIgniter开发我的网站,并使用biostall.com上的谷歌地图库显示谷歌地图API V3 Iam 我创建此链接以显示多个标记: 但我不知道如何显示数据库MySQL中的所有标记,因为我是CI新手,仍然对MVC概念感到困惑:) 我的桌子是destinasi,即结构: id int 长双人 拉特双人床 我希望我能得到很好的答案,我很抱歉,因为我的英语很差 谢谢你使用我
我希望我能得到很好的答案,我很抱歉,因为我的英语很差 谢谢你使用我的图书馆。如果您在此处查看文档PDF: 您将在第20页看到如何从数据库添加标记的示例。看一看,如果你有任何问题就告诉我 史蒂夫是最好的
$coords = $this->model_association->getdata();
// Loop through the coordinates we obtained above and add them to the map
if (is_array($coords) || is_object($coords)){
foreach ($coords as $coordinate) {
$marker = array();
$marker['position'] = $coordinate->latlon;
$marker['animation'] = 'DROP';
$marker['title']= $coordinate->CordiName;
// $marker['infowindow_content']=$coordinate->Address;
$this->googlemaps->add_marker($marker);
}
您好,biostall,页面加载时显示此错误。此页面无法正确加载谷歌地图。请帮助我删除此错误
$coords = $this->model_association->getdata();
// Loop through the coordinates we obtained above and add them to the map
if (is_array($coords) || is_object($coords)){
foreach ($coords as $coordinate) {
$marker = array();
$marker['position'] = $coordinate->latlon;
$marker['animation'] = 'DROP';
$marker['title']= $coordinate->CordiName;
// $marker['infowindow_content']=$coordinate->Address;
$this->googlemaps->add_marker($marker);
}