自訂地圖
您可以透過多種方式自訂 Google 地圖平台 (GMP) 地圖。大多數的這些方法都需要使用地圖 ID 才能存取多種不同的地圖自訂功能。您也可以使用 JSON 樣式手動自訂 GMP 地圖,
使用地圖 ID 自訂地圖
「地圖 ID」是不重複的識別碼,代表單一 Google 地圖例項。地圖 ID 僅限於單一平台:JavaScript、Android、iOS 或靜態地圖。您可以將地圖 ID 與專案建立關聯,並使用地圖 ID 在網站和應用程式中啟用功能,或管理/設定地圖樣式。詳情請參閱「地圖 ID 總覽」。
使用地圖 ID 和雲端式地圖樣式設定進行自訂
您可以使用雲端式地圖樣式,利用地圖 ID 和地圖樣式為使用者打造自訂的路線圖體驗。接著,您就可以視需要在 Cloud 控制台中更新樣式,而無須更新應用程式的程式碼。詳情請參閱「雲端式地圖樣式」。
使用 JSON 樣式手動自訂地圖
您可以手動自訂地圖,為一般地圖類型設定樣式,而且不需要地圖 ID。您必須更新程式碼,才能更新樣式。您無法在同一個應用程式中結合手動地圖樣式設定和雲端式地圖樣式設定。
如要使用 JSON 樣式手動自訂地圖,請參閱「新增樣式化地圖」。
除非另有註明,否則本頁面中的內容是採用創用 CC 姓名標示 4.0 授權,程式碼範例則為阿帕契 2.0 授權。詳情請參閱《Google Developers 網站政策》。Java 是 Oracle 和/或其關聯企業的註冊商標。
上次更新時間:2025-01-17 (世界標準時間)。
[null,null,["上次更新時間:2025-01-17 (世界標準時間)。"],[[["Google Maps Platform (GMP) maps can be customized through various methods, primarily using a map ID."],["Map IDs are unique identifiers associated with a project and a specific platform (JavaScript, Android, iOS, or Static maps) to enable features and manage map styles."],["Cloud-based maps styling allows for the use of map IDs and map styles to customize road maps, with the benefit of updating styles in the Cloud console without code changes."],["Manual map customization using JSON styling is available for styling the normal map type but does not require a map ID and necessitates code updates for any style changes."],["Cloud-based maps styling and manual map styling using JSON cannot be combined within the same application."]]],["Google Maps Platform (GMP) maps can be customized using map IDs or JSON styling. Map IDs, unique identifiers for a single map instance on a specific platform (Android, iOS, JavaScript, or Web Service), enable cloud-based styling and feature management via the Cloud console. JSON styling, which doesn't require a map ID, allows manual map styling but necessitates code updates for any changes. Cloud-based and manual styling cannot be combined. Select a platform to begin, or check out map ID overview and cloud-based map styling.\n"]]