[WordPress] 外掛分享: Google Maps Shell

首頁外掛目錄 › Google Maps Shell
WordPress 外掛 Google Maps Shell 的封面圖片
全新外掛
安裝啟用
尚無評分
4845 天前
最後更新
問題解決
WordPress 3.4+ v1.0 上架:2012-12-11

內容簡介

這個外掛是給開發人員使用,並旨在用於啟用 Google 地圖整合。雖然它帶有一個預設位置,但開發人員將希望提供一個巢狀數組的位置數據給外掛。這些數據可以手動編輯或通過外部手段檢索。

您需要使用過濾器 ab_google_maps_markers 並返回新的巢狀數組。

範例:

function new_array( $markers ) { $markers = (object) array(
array(
'lat' => '30.266132',
'lon' => '-97.745825', 'title' => 'Gingerman Austin', 'address' => '301 Lavaca St, Austin TX 78701' ), array( 'lat' => '30.2658', 'lon' => '-97.735691', 'title' => 'Easy Tiger Bake Shop and Beer Garden', 'address' => '709 East 6th St, Austin TX 78701' ), ); return $markers; } add_filter( 'ab_google_maps_markers', 'new_array' );

外掛標籤

開發者團隊

⬇ 下載最新版 (v1.0) 或搜尋安裝

① 下載 ZIP → 後台「外掛 › 安裝外掛 › 上傳外掛」
② 後台搜尋「Google Maps Shell」→ 直接安裝(推薦)

原文外掛簡介

This plugin is for developers and is meant to be used to enable Google Maps integration. While it does come with a default location, developers will want to feed the plugin a nested array of location data. This data can be manually curated or retrieved through external means.
You need to use the filter ab_google_maps_markers and return the new nested array.
Example:
function new_array( $markers ) { $markers = (object) array(
array(
'lat' => '30.266132',
'lon' => '-97.745825', 'title' => 'Gingerman Austin', 'address' => '301 Lavaca St, Austin TX 78701' ), array( 'lat' => '30.2658', 'lon' => '-97.735691', 'title' => 'Easy Tiger Bake Shop and Beer Garden', 'address' => '709 East 6th St, Austin TX 78701' ), ); return $markers; } add_filter( 'ab_google_maps_markers', 'new_array' );

延伸相關外掛

文章
Filter
Apply Filters
Mastodon