{ "info": { "author": "David D Lowe", "author_email": "daviddlowe.flimm@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 5 - Production/Stable", "Framework :: Django", "Framework :: Django :: 1.10", "Framework :: Django :: 1.11", "Framework :: Django :: 1.8", "Framework :: Django :: 1.9", "Framework :: Django :: 2.0", "Framework :: Django :: 2.1", "License :: OSI Approved :: MIT License", "Programming Language :: Python :: 2", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.2", "Programming Language :: Python :: 3.3", "Programming Language :: Python :: 3.4", "Programming Language :: Python :: 3.5", "Programming Language :: Python :: 3.6", "Programming Language :: Python :: 3.7" ], "description": ".. image:: https://img.shields.io/pypi/v/django-fullurl.svg\n :target: https://pypi.org/project/django-fullurl/\n :alt: django-fullurl on PyPI\n\n.. image:: https://img.shields.io/pypi/l/django-fullurl.svg\n :target: https://pypi.org/project/django-fullurl/\n :alt: django-fullurl on PyPI\n\n.. image:: https://img.shields.io/pypi/wheel/django-fullurl.svg\n :target: https://pypi.org/project/django-fullurl/\n :alt: django-fullurl on PyPI\n\n.. image:: https://img.shields.io/pypi/pyversions/django-fullurl.svg\n :target: https://pypi.org/project/django-fullurl/\n :alt: django-fullurl on PyPI\n\n.. image:: https://travis-ci.org/Flimm/django-fullurl.svg?branch=master\n :target: https://travis-ci.org/Flimm/django-fullurl\n :alt: Travis CI for django-fullurl (master branch)\n\n.. image:: https://img.shields.io/badge/Say%20Thanks-!-1EAEDB.svg\n :target: https://saythanks.io/to/Flimm\n :alt: Say Thanks!\n\n------\n\nIntroduction\n=============\n\n**django-fullurl** adds three new template tags to Django: ``fullurl``, ``fullstatic``, and ``buildfullurl``.\n\n``fullurl`` and ``fullstatic`` behave like ``url`` and ``static`` respectively, but they always return an absolute URL with the scheme and authority/domain parts.\n\nFor example, take this ``url`` tag:\n\n.. code:: html+django\n\n {% url \"articles:article\" slug=\"hello\" %}\n\nIn our example, this prints::\n\n /articles/hello\n\nThis is called by some an absolute URL, because it begins with a forward-slash. However, it is not an *absolute* absolute URL, because it does not contain the scheme and authority parts.\n\nIf we replace ``url`` with ``fullurl``, it will print this result::\n\n http://example.com/articles/hello\n\nBehind the scenes, it uses `request.build_absolute_uri `__ to determine the correct scheme and authority/domain parts.\n\nIn the same way that ``fullurl`` extends ``url``, ``fullstatic`` extends the ``static`` template tag.\n\n``buildfullurl`` takes a relative URL as an argument, and prints an absolute URL with the scheme and authority parts. For example:\n\n.. code:: html+django\n\n {% buildfullurl article.cover.url %}\n\nInstallation\n============\n\nRun on the command-line::\n\n $ pip install django-fullurl\n\nMake sure these two apps are included in your ``INSTALLED_APPS`` settings:\n\n.. code:: python\n\n INSTALLED_APPS = [\n 'django.contrib.staticfiles',\n 'fullurl',\n # ...\n ]\n\nMake sure ``django.template.context_processors.request`` is included in your context processors.\n\nExample usage\n=============\n\nOpenGraph\n---------\n\nOpenGraph URLs need to be absolute, including scheme and authority parts. Here's how you can use ``fullurl`` and ``fullstatic`` to help with this:\n\n.. code:: html+django\n\n {% load fullurl %}\n\n \n \n\n\nYou can convert a URL from relative to absolute using ``buildfullurl`` tag:\n\n.. code:: html+django\n\n {% load fullurl %}\n\n \n \n\nFacebook static share link\n--------------------------\n\nIf you want to create a Facebook share button using a link, you can use the ``sharer.php`` feature. The value for the ``u`` query parameter needs to be an absolute URL, encoded using the ``urlencode`` filter, like this:\n\n.. code:: html+django\n\n {% load fullurl %}\n\n \n Share\n \n\nSee also\n========\n\nHere are some alternatives, in alphabetical order:\n\n- `django-absoluteuri `__ (`GitHub `__, `Django Packages `__) provides two template tags: ``absoluteuri`` and ``absolutize``. Unlike this app, it uses the site framework to determine the domain to use, which could be an additional database query. This can be useful in some situations, for instance when creating emails.\n- `django-absoluteurl `__ (`GitHub `__, `Django Packages `__) provides a template tag ``absoluteurl`` that works in a similar fashion as ``fullurl``. It does not seem to work in Python 2, or with newer Django versions, however.\n- django-full-url (`GitHub `__) allows you to get specific parts of the current URL using code like ``{{ url_parts.domain }}``, among other things. It does not provide the same functionality as this app, the naming similarity was unintentional.\n- `django-urltags `__ (`Django Packages `__) provides a few template tags, including ``absurl``, but it hasn't been updated since 2012 and it doesn't seem to work on recent Django versions.\n\n\nChangelog\n=========\n\n1.0\n---\n\n* First release marked as stable\n* Support Django 2.0 and 2.1\n* Support Python 3.7\n\n0.5\n---\n\n* Add new template tag: ``buildfullurl``\n* Relicense to MIT\n* Support Django 1.11\n\nThank you to `Jakub Dolej\u0161ek `__ for the contribution\nof the new template tage ``buildfullurl``.\n\n0.4\n---\n\n* Fix RST syntax errors in README.rst\n\n0.3\n---\n\n* Fix and improve documentation\n* Add CHANGELOG.rst to MANIFEST.in\n\n0.2\n---\n\n* Add support for Django 1.8 and Django 1.9, in addition to Django 1.10.\n* Add support for Python 2.7, Python 3.2, 3.3, 3.4 and 3.5, in addition to Python 3.6.\n\n0.1\n---\n\n* First release on PyPI.\n\n\n", "description_content_type": "text/x-rst", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "", "keywords": "django", "license": "mit", "maintainer": "", "maintainer_email": "", "name": "django-fullurl", "package_url": "https://pypi.org/project/django-fullurl/", "platform": "", "project_url": "https://pypi.org/project/django-fullurl/", "project_urls": { "Change log": "https://github.com/Flimm/django-fullurl/blob/master/CHANGELOG.rst", "GitHub": "https://github.com/Flimm/django-fullurl", "Say Thanks!": "https://saythanks.io/to/Flimm" }, "release_url": "https://pypi.org/project/django-fullurl/1.0/", "requires_dist": [ "Django (>=1.8)" ], "requires_python": ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, <4", "summary": "Adds three template tags to Django: `fullurl`, `fullstatic` and `buildfullurl`. The template tag `fullurl` acts just like `url`, but it always prints absolute URLs with scheme and domain", "version": "1.0" }, "last_serial": 4973219, "releases": { "0.1": [ { "comment_text": "", "digests": { "md5": "00390aee3ba7113f21783eb1168b1dcf", "sha256": "9edd1e42b21446ec9181b904bed0fe7d2c0b0266618bf92ab1db72571f262bcc" }, "downloads": -1, "filename": "django_fullurl-0.1-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "00390aee3ba7113f21783eb1168b1dcf", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 4291, "upload_time": "2017-03-01T20:15:17", "url": "https://files.pythonhosted.org/packages/ff/ce/f065d46c15f69393b8f68fecf142cf6e3c7670aa3729fe9cc217af1c5d62/django_fullurl-0.1-py2.py3-none-any.whl" } ], "0.2": [ { "comment_text": "", "digests": { "md5": "125ad1783cb3e57a4da36f905a0d7d83", "sha256": "ce7ae1d13a7e6ad16be382568959708413c4e8c3cdcd76c39bd3d2caef01c466" }, "downloads": -1, "filename": "django_fullurl-0.2-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "125ad1783cb3e57a4da36f905a0d7d83", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 6325, "upload_time": "2017-03-02T08:56:40", "url": "https://files.pythonhosted.org/packages/53/27/897718e904599ba8e4809a9ecdd51cc960ff10a4065a3e3e148ad41019cb/django_fullurl-0.2-py2.py3-none-any.whl" } ], "0.3": [ { "comment_text": "", "digests": { "md5": "21a48c82566194e1ae69b98723d226bf", "sha256": "b3987595bbdd598664918708ac0b617084568004039fea045baaa7e30a88ab7f" }, "downloads": -1, "filename": "django_fullurl-0.3-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "21a48c82566194e1ae69b98723d226bf", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 7190, "upload_time": "2017-03-02T10:46:08", "url": "https://files.pythonhosted.org/packages/2f/d0/f249cc1e0362304b4d5bd923d5353011279cc6e9b36a75e7fecedf08a9b8/django_fullurl-0.3-py2.py3-none-any.whl" } ], "0.4": [ { "comment_text": "", "digests": { "md5": "b24104d89dc3407bc5b10f3186ef41b8", "sha256": "5e0a293adeda59a65712d631fd07c734e0832a353729946aeb170c91444313a2" }, "downloads": -1, "filename": "django_fullurl-0.4-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "b24104d89dc3407bc5b10f3186ef41b8", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 7249, "upload_time": "2017-03-02T11:28:49", "url": "https://files.pythonhosted.org/packages/31/c5/5913c034ce61506291d520e378f3eb1f94e07b1e7daebc435c4c7410928b/django_fullurl-0.4-py2.py3-none-any.whl" } ], "0.5": [ { "comment_text": "", "digests": { "md5": "14a1d66e66812b75a9b0a0716664d5b9", "sha256": "f700aadbd8d4c20df5976c1962a21e7eed3697c05394358e51cd26fb4cefb11d" }, "downloads": -1, "filename": "django_fullurl-0.5-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "14a1d66e66812b75a9b0a0716664d5b9", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 8100, "upload_time": "2017-05-17T15:06:48", "url": "https://files.pythonhosted.org/packages/03/93/d28a84d5ff741abaebd16a91585ec2a96bda7c5146f19bbbc2e4abfb53de/django_fullurl-0.5-py2.py3-none-any.whl" } ], "1.0": [ { "comment_text": "", "digests": { "md5": "28774fcfddd8ad9c910d55c0d4555e71", "sha256": "68097baeaa55088b1803d18e97a24d4540fe4c13293f0a2cea4fd99c5b99f225" }, "downloads": -1, "filename": "django_fullurl-1.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "28774fcfddd8ad9c910d55c0d4555e71", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, <4", "size": 6466, "upload_time": "2019-03-22T15:04:30", "url": "https://files.pythonhosted.org/packages/31/05/cc1c2fa6218c543f3621570ad1834ff28dfaec912ffedbae518d63b2aabf/django_fullurl-1.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "fab8f373fa474eba204f84f37851a066", "sha256": "90e548214278bf42aec0bfdfb28c335562e1d904074962f11f24050ef30d3f81" }, "downloads": -1, "filename": "django-fullurl-1.0.tar.gz", "has_sig": false, "md5_digest": "fab8f373fa474eba204f84f37851a066", "packagetype": "sdist", "python_version": "source", "requires_python": ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, <4", "size": 5935, "upload_time": "2019-03-22T15:04:32", "url": "https://files.pythonhosted.org/packages/c4/c2/c09040d96e5d73f128af07cb708e41ee6dfeb8337b0a949b1f4cb2cf970d/django-fullurl-1.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "28774fcfddd8ad9c910d55c0d4555e71", "sha256": "68097baeaa55088b1803d18e97a24d4540fe4c13293f0a2cea4fd99c5b99f225" }, "downloads": -1, "filename": "django_fullurl-1.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "28774fcfddd8ad9c910d55c0d4555e71", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, <4", "size": 6466, "upload_time": "2019-03-22T15:04:30", "url": "https://files.pythonhosted.org/packages/31/05/cc1c2fa6218c543f3621570ad1834ff28dfaec912ffedbae518d63b2aabf/django_fullurl-1.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "fab8f373fa474eba204f84f37851a066", "sha256": "90e548214278bf42aec0bfdfb28c335562e1d904074962f11f24050ef30d3f81" }, "downloads": -1, "filename": "django-fullurl-1.0.tar.gz", "has_sig": false, "md5_digest": "fab8f373fa474eba204f84f37851a066", "packagetype": "sdist", "python_version": "source", "requires_python": ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, <4", "size": 5935, "upload_time": "2019-03-22T15:04:32", "url": "https://files.pythonhosted.org/packages/c4/c2/c09040d96e5d73f128af07cb708e41ee6dfeb8337b0a949b1f4cb2cf970d/django-fullurl-1.0.tar.gz" } ] }