taviroquai / mapserver
MapServer package for Laravel
v2.0.0
2015-03-06 15:19 UTC
Requires
- php: >=5.4.0
- guzzlehttp/guzzle: ~4.0
- illuminate/support: 5.0.*
This package is auto-updated.
Last update: 2024-10-08 06:51:56 UTC
README
Install
Add to composer.json
require: { "taviroquai/mapserver": "~2.0" }
Add Service Provider on app/config/app.php
'providers' => array( ... 'Taviroquai\Mapserver\MapserverServiceProvider', ),
php composer.phar update
Usage
// Create a MapServer instance $mapserver = new \Taviroquai\Mapserver\Mapserver(); // Create a new map object (mapObj) $map = $mapserver->createMap( 'test', storage_path('default.map'), storage_path('template.html') ); // Return WMS capabilities $response = $mapserver->getCapabilitiesResponse($map); // Return map image as Illuminate response $response = $mapserver->getImageResponse($map); return $response;
Requirements
Of course Laravel 5, Mapserver and MapScript must be installed
Features
- Check whether MapServer is installed or not at the requested machine
- Opens a mapfile
- Export a mapfile
- Return a GetCapabilities response as Illuminate\HTTP\Response
- Creates map image as Illuminate\HTTP\Response
Call for Collab
All GEO lovers are invited to fork and grow this project ;)