Add options to output polygon in various formats: polygon_geojson=1&polygon_svg=1&polygon_kml=1&polygon_text=1 They can be all used at the same time if prefered. Where format and polygon type are compatible output is as native type e.g. format=json&polygon_geojson=1

This commit is contained in:
Brian Quinion
2012-11-06 00:08:01 +00:00
parent c0d9ba7e0c
commit 753d2ac79f
4 changed files with 117 additions and 25 deletions

View File

@@ -49,6 +49,26 @@
$aPlace['address'] = $aPointDetails['address'];
}
if (isset($aResult['asgeojson']))
{
$aPlace['geojson'] = json_decode($aResult['asgeojson']);
}
if (isset($aResult['assvg']))
{
$aPlace['svg'] = $aResult['assvg'];
}
if (isset($aResult['astext']))
{
$aPlace['geotext'] = $aResult['astext'];
}
if (isset($aResult['askml']))
{
$aPlace['geokml'] = $aResult['askml'];
}
$aFilteredPlaces[] = $aPlace;
}