function leaflet_widget_process_geojson in Leaflet Widget for Geofield 7
Same name and namespace in other branches
- 7.2 leaflet_widget.module \leaflet_widget_process_geojson()
1 call to leaflet_widget_process_geojson()
File
- ./
leaflet_widget.module, line 171
Code
function leaflet_widget_process_geojson($geojson) {
$geom = geoPHP::load($geojson, 'json');
$type = $geom
->geometryType();
$result = array(
'wkt' => $geom
->out('wkt'),
);
geofield_compute_values($result, 'wkt');
return $result;
}