Skip to main content

A Django template filter for displaying longitude and latitude in degrees-minutes-seconds notation

Project description


django-dms is a Django template filter for displaying decimal degrees of angles (longitude and latitude) in the Degrees-Minutes-Seconds notation.

It contains the filters longitude and latitude. They both take a number as input and convert it into a DMS value. The filter longitude accepts any number between -180 and 180, the filter latitude accepts any number between -90 and 90. If the input value is not a number or is a number outside the before mentioned ranges respectively, then the input is displayed without any change and the filters don’t have any effect.


You can install django-dms with pip:

pip install django-dms


To use the filters you have to include the app in the of your Django project:

    # other entries

In your templates you can use the template filters like this:

{% load dms %}
{{ 38.8897|latitude }}

The output will be:

38° 53' 23" N

Project details

Download files

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

Files for django-dms, version 0.1.1b0
Filename, size File type Python version Upload date Hashes
Filename, size django-dms-0.1.1b0.tar.gz (17.0 kB) File type Source Python version None Upload date Hashes View

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page