[mapserver-users] Corrupted zipped shapefiles from WFS
Keith Moss
Keith.Moss at landgate.wa.gov.au
Tue Nov 1 23:50:56 PDT 2011
Hi list,
We're having a bit of an issue with the zipped shapefiles we're getting back
from WFS GetFeature requests. Winzip claims that they're all corrupted* but,
oddly, 7zip can open and extract the perfectly valid shapefile without
issue. We tried to unzip the file with PHP's inbuilt ZIPArchive class, but
that also had issues - it could read the files in there but would extract
0KB length files.
Other output formats - CSV, GML, etc - work without issue. We've reproduced
the issue on two separate Windows-based servers (2008 & 2003).
We've noticed in the corrupted zip files that the file starts with:
"Content-Disposition: attachment; filename=result.zip
Content-Type: application/zip" (when we open it in Notepad). We've tried
removing this, but it didn't help.
Can anyone on the list, or one of the developers, shed any light on the
situation?
I've attached a simple test case with an example shapefile, would someone be
able to try it on their setup for us please?
We're using PHP MapScript with MapServer 6.0.1 (MS4W 3.0.3) / PHP 5.3.6.
* The WinZip error: "error [<path>.zip]: start of central directory not
found; Zip file corrupt."
http://osgeo-org.1803224.n2.nabble.com/file/n6954263/shapezip.zip
shapezip.zip
--
View this message in context: http://osgeo-org.1803224.n2.nabble.com/Corrupted-zipped-shapefiles-from-WFS-tp6954263p6954263.html
Sent from the Mapserver - User mailing list archive at Nabble.com.
More information about the MapServer-users
mailing list