Adds a Leaflet map field to the Advanced Custom Fields plugin.
This plugin adds a Leaflet map field to the Advanced Custom Fields plugin.
You can add a leaflet map field using ACF like the Google Map field.
Uses the classic ACF get_field('field_name')
function to get field data (lat, lng, address & zoom).
Warning, the get_field()
function does not display the map itself, for this, use the leaflet js map documentation directly
This ACF field type is compatible with:
* ACF 5 only (Pro & Free)
NB: If you’re using the ACF 4 Free version, you can upgrade to version 5 step by step on this page
From your WordPress dashboard
1. Visit Plugins > Add New
2. Search for “Advanced Custom Fields: Leaflet Field”
3. Activate “Advanced Custom Fields: Leaflet Field” from your Plugins page
4. Create ACF new leaflet map field from “Custom Fields” menu item
From your WordPress dashboard
1. Visit Plugins > Add New
2. Search for “Advanced Custom Fields: Leaflet Field”
3. Activate “Advanced Custom Fields: Leaflet Field” from your Plugins page
4. Create ACF new leaflet map field from “Custom Fields” menu item
<?php var_dump( get_field('my-field-name') ); ?>