mirror of
https://github.com/klokantech/tileserver-php.git
synced 2025-08-24 07:02:57 +02:00
Compare commits
8 Commits
Author | SHA1 | Date | |
---|---|---|---|
|
987f01c85e | ||
|
ed19c0a414 | ||
|
04a9abf170 | ||
|
c3e9b41110 | ||
|
6c840820f0 | ||
|
d4c1996815 | ||
|
3181142368 | ||
|
5fca96fd91 |
34
.htaccess
34
.htaccess
@@ -1,27 +1,33 @@
|
||||
# tileserver.php integration with Apache via .htaccess
|
||||
|
||||
# Restrictions for data crawlers
|
||||
#Options -Indexes
|
||||
|
||||
# Optional CORS header for cross-domain origin access to all data
|
||||
#<ifModule mod_headers.c>
|
||||
# Header set Access-Control-Allow-Origin *
|
||||
#</ifModule>
|
||||
|
||||
# Mapping of the WMTS standardized URLs to real files and XML capabilities to tileserver.php
|
||||
|
||||
#check htaccess functionality
|
||||
DirectoryIndex tileserver.php
|
||||
|
||||
RewriteEngine on
|
||||
|
||||
#some hostings require RewriteBase e.g. 1&1.com
|
||||
# Option: some hostings require RewriteBase e.g. 1&1.com
|
||||
#RewriteBase /
|
||||
#RewriteBase /server/
|
||||
#RewriteBase /directory/
|
||||
|
||||
#some hostings require -MultiViews e.g. 1&1.com
|
||||
# Option: some hostings require -MultiViews e.g. 1&1.com
|
||||
#Options -MultiViews
|
||||
|
||||
# Option: Restrictions for data crawlers
|
||||
#Options -Indexes
|
||||
|
||||
# Option: CORS header for cross-domain origin access to all data
|
||||
#<ifModule mod_headers.c>
|
||||
# Header set Access-Control-Allow-Origin *
|
||||
#</ifModule>
|
||||
|
||||
# Block direct downloading of .mbtiles
|
||||
<FilesMatch "\.mbtiles$">
|
||||
Order Allow,Deny
|
||||
Deny from all
|
||||
</FilesMatch>
|
||||
|
||||
# Mapping of the WMTS standardized URLs to real files and XML capabilities to tileserver.php
|
||||
|
||||
# WMTS RESTful
|
||||
# ------------
|
||||
# The file can be accessed directly:
|
||||
@@ -69,4 +75,4 @@ RewriteRule .* - [E=HTTP_IF_NONE_MATCH:%{HTTP:If-None-Match}]
|
||||
RewriteCond %{REQUEST_FILENAME} !-f
|
||||
RewriteCond %{REQUEST_FILENAME} !-d
|
||||
RewriteCond $1 !^(tileserver\.php)
|
||||
RewriteRule ^(.*)$ tileserver.php?/$1 [L,QSA]
|
||||
RewriteRule ^(.*)$ tileserver.php?/$1 [L,QSA]
|
||||
|
36
README.md
36
README.md
@@ -1,10 +1,11 @@
|
||||
=================================================
|
||||
TileServer PHP - OGC Web Map Tiling Server (WMTS)
|
||||
=================================================
|
||||
|
||||
This server distributes maps to desktop, web, and mobile applications from
|
||||
a standard Apache+PHP web hosting.
|
||||
|
||||
Try a live demo at: http://tileserver.maptiler.com/
|
||||
|
||||
It is a free and open-source project implementing OGC WMTS standard for
|
||||
pre-rendered map tiles made with [MapTiler](http://www.maptiler.com/), GDAL2Tiles,
|
||||
or available as MBTiles files.
|
||||
@@ -13,9 +14,9 @@ It is the easiest and cheapest way how to serve zoomable maps in a
|
||||
standardized way - practically from any ordinary web hosting.
|
||||
|
||||
It is easy to install - just copy the project files to a PHP-enabled
|
||||
directory along with your map data containing metadata.json file.
|
||||
directory along with your map data.
|
||||
|
||||
It comes with an online interface showing the list of the maps and step-by-step guides for desktop GIS software:
|
||||
It comes with an online interface showing the list of the maps and step-by-step guides for online mapping libraries (Google Maps API, Leaflet, OpenLayers, OL3, MapBox JS, ArcGIS JS) and various desktop GIS software:
|
||||
|
||||

|
||||
|
||||
@@ -27,7 +28,11 @@ web hostings.
|
||||
Tiles are served directly by Apache with mod_rewrite rules as static files
|
||||
and therefore are very fast and with correct HTTP caching headers.
|
||||
Only XML metadata are delivered via PHP.
|
||||
MBTiles are served via PHP, unless they are unpacked with mbutil.
|
||||
MBTiles are served via PHP, and are therfore slower, unless they are unpacked with mbutil.
|
||||
|
||||
[MapTiler](http://www.maptiler.com/) can render GeoTIFF, ECW, MrSID, GeoPDF into compatible map tiles. JPEG, PNG, GIF and TIFF with scanned maps or images without geolocation can be turned into standard map layers with the visual georeferencing functionality (http://youtu.be/eJxdCe9CNYg).
|
||||
|
||||
[](http://www.maptiler.com/)
|
||||
|
||||
Requirements:
|
||||
-------------
|
||||
@@ -40,8 +45,7 @@ Requirements:
|
||||
Installation:
|
||||
-------------
|
||||
|
||||
Download the project files as a zip archive or source code from GitHub and
|
||||
unpack it into a web-hosting of your choice.
|
||||
Download the project files as a [zip archive](https://github.com/klokantech/tileserver-php/archive/master.zip) or source code from GitHub and unpack it into a web-hosting of your choice.
|
||||
|
||||
If you access the web address relevant to the installation directory,
|
||||
the TileServer.php Server should display you a welcome message and further
|
||||
@@ -52,14 +56,12 @@ tiles rendered with [MapTiler](http://www.maptiler.com/).
|
||||
|
||||
Tiles produced by open-source GDAL2Tiles or MapTiler and tiles in .mbtiles
|
||||
files can be easily converted to required structure (XYZ with top-left origin
|
||||
and metadata.json file).
|
||||
|
||||
The OpenSource utility mbutil (https://github.com/mapbox/mbutil) produces
|
||||
and metadata.json file). The open-source utility [mbutil](https://github.com/mapbox/mbutil) produces
|
||||
exactly the required format.
|
||||
|
||||
Direct reading of .mbtiles files is supported, but with decreased performance
|
||||
compared to the static files in a directory. Therefore the data management,
|
||||
especially upload over FTP or similar protocols, is easier.
|
||||
compared to the static files in a directory. The advantage is easier data management,
|
||||
especially upload over FTP or similar protocols.
|
||||
|
||||
Supported protocols:
|
||||
--------------------
|
||||
@@ -212,9 +214,10 @@ Credits / Contributors
|
||||
Project developed initially by Klokan Technologies GmbH, Switzerland in
|
||||
cooperation with National Oceanic and Atmospheric Administration - NOAA, USA.
|
||||
|
||||
Petr Pridal - Klokan Technologies GmbH <petr.pridal@klokantech.com>
|
||||
Jason Woolard - NOAA <jason.woolard@noaa.gov>
|
||||
Jon Sellars - NOAA <jon.sellars@noaa.gov>
|
||||
- Petr Pridal - Klokan Technologies GmbH <petr.pridal@klokantech.com>
|
||||
- Jason Woolard - NOAA <jason.woolard@noaa.gov>
|
||||
- Jon Sellars - NOAA <jon.sellars@noaa.gov>
|
||||
- Dalibor Janak - Klokan Technologies GmbH <dalibor.janak@klokantech.com>
|
||||
|
||||
Tested WMTS/TMS clients
|
||||
-----------------------
|
||||
@@ -223,13 +226,16 @@ Tested WMTS/TMS clients
|
||||
http://www.qgis.org/
|
||||
- ESRI ArcGIS Desktop 10.1+ - native WMTS implementation supported
|
||||
http://www.esri.com/software/arcgis/arcgis-for-desktop
|
||||
- ESRI ArcGIS Online - loading via WMTS protocol
|
||||
http://www.arcgis.com/
|
||||
- ArcBruTiles plugin for ArcGIS 9.3+ - via TMS endpoint
|
||||
http://arcbrutile.codeplex.com/
|
||||
- OpenLayers WMTS Layer - including parsing GetCapabilities
|
||||
http://www.openlayers.org/
|
||||
- GAIA - native WMTS (issues with 3857 to be fixed)
|
||||
http://www.thecarbonproject.com/gaia.php
|
||||
- MapBox.js - the loading of maps via TileJSON
|
||||
- MapBox.js - the loading of maps via TileJSON, interaction layer supported
|
||||
https://www.mapbox.com/mapbox.js
|
||||
|
||||
BSD License
|
||||
-----------
|
||||
|
Reference in New Issue
Block a user