You are here

function geofield_form_latlon_map in Geofield 7

Create LatLon Helper Map.

1 call to geofield_form_latlon_map()
geofield_widget_openlayers_afterbuild in ./geofield.widgets.inc
Callback for afterbuild for widget for js addition to

File

./geofield.widgets.inc, line 243
Provides field widget hooks for geofield module.

Code

function geofield_form_latlon_map($defaults = array(), $map_name) {

  // Pass variables etc. to javascript
  // Set up our map to help set lat and lon
  // This map will always be projected as 4326 and use just the default map preset
  $map_data = openlayers_map_load($map_name);
  $map = $map_data->data;
  return openlayers_render_map($map);
}