Skip to main content
Help us improve Python packaging – donate today!

Absolute Url is an app for creating absolute urls in Django templates.

Project Description

=====
Django Absolute Url Template Tag
=====

Absolute Url is an app for creating absolute urls in Django templates. It works like built-in Django ``url`` template tag but with absolute urls.

Installation
-----------

Install using PIP

``pip install django-absoluteurl``

Add "absoluteurl" to your INSTALLED_APPS setting like this:

INSTALLED_APPS = (
...
'absoluteurl',
)


Usage
-----------

First load it in Django template and use it as a tag.

{% load absoluteurl %}

This is simplest example:
{% absoluteurl 'name_for_your_url' %}

This is an absolute url for some object:
{% absoluteurl 'your_namespace:your_view' some_id=some_object.id %}

You can also use it with 'as' form:
{% absoluteurl 'your_namespace:your_view' some_id=some_object.id as abs_url %}
{{ abs_url }}


Credits
-------------
Created by Bartosz Gryszko, 2014
MIT License

Release history Release notifications

This version
History Node

1.0

Download files

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

Filename, size & hash SHA256 hash help File type Python version Upload date
django-absoluteurl-1.0.tar.gz (4.8 kB) Copy SHA256 hash SHA256 Source None Jul 16, 2014

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging CloudAMQP CloudAMQP RabbitMQ AWS AWS Cloud computing Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page