The Mapping module uses GeoJSON. When using tools like ogr2ogr or
Geoserver to generate GeoJSON from shapefiles, I have noticed that
sometimes unnecessary zeros are added to the end of coordinates. This
makes files become very large when there are thousands of points.
Therefore, I have written the attached PHP script (basically a regex)
to remove unwanted decimals from a GeoJSON file. It does not round,
just truncate.

Knut

<<attachment: file_upload.php>>

_______________________________________________
Mailing list: https://launchpad.net/~dhis2-devs
Post to     : [email protected]
Unsubscribe : https://launchpad.net/~dhis2-devs
More help   : https://help.launchpad.net/ListHelp

Reply via email to