Custom Fields
Re-Envisioned
Support Meta Box Geolocation Open Street Maps: Exposing Latitude, Longitude, Zoom Level

  • Creator
    Topic
  • #23863
    Mauro
    Participant

    Hello Anh,
    Following up to this conversation from 2 years ago, I need to expose Lat, Lon and Zoom level from the OMS map so that content managers can fine tune this or paste the coordinates from a different source.

    https://metabox.io/support/topic/open-street-maps-binding-of-latitude-and-longitude-keeping-the-map-in-english/

    I tried with a similar code but it’s not working.
    Can you help?

    array(
                    'type' => 'text',
                    'name' => 'Address',
                    'id'    => 'address',
                    'desc' => 'Use this field to autocomplete the address and add the coordinates automatically.',
                ),
                array(
                    'id' => 'location',
                    'type' => 'osm',
                    'name' => 'Location',
                    'address_field' => 'address',
                    'language' => 'en',
                    'desc' => 'You can click on "find address" below the map to update the pin location on the map. Fill the address field above to update the coordinates.',
                ),
                array(
                    'type' => 'text',
                    'name' => 'Latitude',
                    'id'    => 'latitude',
                    'binding' => 'lat' // lat,lng
                ),
                array(
                    'type' => 'text',
                    'name' => 'Longitude',
                    'id'    => 'longitude',
                    'binding' => 'lng' // lat,lng
                ),
  • You must be logged in to reply to this topic.