wesmiler 41b6d2f447 We smiler 代码部署提交 пре 5 година
..
src 41b6d2f447 We smiler 代码部署提交 пре 5 година
CHANGELOG.md 41b6d2f447 We smiler 代码部署提交 пре 5 година
CONTRIBUTING.md 41b6d2f447 We smiler 代码部署提交 пре 5 година
LICENSE 41b6d2f447 We smiler 代码部署提交 пре 5 година
README.md 41b6d2f447 We smiler 代码部署提交 пре 5 година
codecov.yml 41b6d2f447 We smiler 代码部署提交 пре 5 година
composer.json 41b6d2f447 We smiler 代码部署提交 пре 5 година
phpunit.xml 41b6d2f447 We smiler 代码部署提交 пре 5 година

README.md

shapefile

ShapeFile library for PHP

Build Status codecov.io Scrutinizer Code Quality Packagist

Features

Currently the 2D and 3D variants except MultiPatch of the ShapeFile format as defined in https://www.esri.com/library/whitepapers/pdfs/shapefile.pdf. The library currently supports reading and editing of ShapeFiles and the Associated information (DBF file). There are a lot of things that can be improved in the code, if you are interested in developing, helping with the documentation, making translations or offering new ideas please contact us.

Installation

Please use Composer to install:

composer require phpmyadmin/shapefile

To be able to read and write the associated DBF file, you need dbase extension:

pecl install dbase
echo "extension=dbase.so" > /etc/php5/conf.d/dbase.ini

Documentation

The API documentation is available at https://develdocs.phpmyadmin.net/shapefile/.

Usage

To read shape file:

$shp = new \PhpMyAdmin\ShapeFile\ShapeFile(0);
$shp->loadFromFile('path/file.*');

History

This library is based on BytesFall ShapeFiles library written by Ovidio (ovidio AT users.sourceforge.net). The library has been embedded in phpMyAdmin for years and slowly developed there. At one point people started to use our version rather than the original library and that was the point we decided to make it separate package.