O'Reilly logo

Python Geospatial Development - Second Edition by Erik Westra

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Summary

In this chapter, we continued our implementation of the ShapeEditor by adding three important functions: the "list" view, and the ability to import and export shapefiles. While these aren't very exciting features, they are a crucial part of the ShapeEditor.

In the process of implementing these features, we have learned the following:

  • Using Django's templating language to display a list of records within a web page.
  • Using the zipfile standard library module to extract the contents of an uploaded shapefile before opening that shapefile using OGR.
  • You will need to "wrap" Polygon and LineString geometries when importing data from a shapefile into a PostGIS database, to avoid problems caused by a shapefile's inability to distinguish between Polygons ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required