Skip to main content

Serve maps from MBTiles files using Django

Project description

django-mbtiles serves maps from MBTiles files using Django. It mainly relies on landez.

INSTALL

pip install -r requirements.txt
python setup.py install

USAGE

  • Add mbtilesmap to your INSTALLED_APPS

  • Make sure you have 'django.core.context_processors.static' in your context processors

  • Include mbtilesmap urls into your project

urlpatterns = patterns('',
    ...
    ...
    url(r'^', include('mbtilesmap.urls', namespace='mb', app_name='mbtilesmap')),
)
  • Add the HTML header and call the template tag

{% load mbtilesmap_tags %}
...
{% block head %}
{% include "mbtilesmap/head.html" %}
{{ block.super }}
{% endblock head %}

...
...
{% mbtilesmap filename %}

Example

Find a working demo project (MBTiles maps browser livembtiles) in the example/ folder (see dedicated README.rst file).

AUTHORS

makinacom

LICENSE

  • Lesser GNU Public License

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

django-mbtiles-1.0.tar.gz (41.2 kB view details)

Uploaded Source

File details

Details for the file django-mbtiles-1.0.tar.gz.

File metadata

File hashes

Hashes for django-mbtiles-1.0.tar.gz
Algorithm Hash digest
SHA256 71bf2d9d3ea245e5d923cff340fac521dd452b9ee2f3fcfa07f3624ecac094c6
MD5 73e3966dea8f97d6ec010ba5afb992fe
BLAKE2b-256 59d1034fa3128510608cd538dc50a3e531aedb3fb7436ec900ffa12fd7e3d006

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page