Skip to main content

Django url2template map

Project description

Installation

$ pip install django-url2template

settings.py

INSTALLED_APPS+=['django_url2template']

migrate

$ python manage.py migrate

views.py

from django.shortcuts import render
from django_url2template.utils import get_template_name

template_name = get_template_name(request.path[1:])
if template_name:
    return render(request, template_name, {})
### Models
model|table|columns/fields
-|-|-
`Map`|`django_url2template_map`|id,url,template_name

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_url2template-1.0.0.tar.gz (2.2 kB view details)

Uploaded Source

File details

Details for the file django_url2template-1.0.0.tar.gz.

File metadata

  • Download URL: django_url2template-1.0.0.tar.gz
  • Upload date:
  • Size: 2.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.0 CPython/3.12.3

File hashes

Hashes for django_url2template-1.0.0.tar.gz
Algorithm Hash digest
SHA256 ab782ab96c8251204ac9b9cd57ffba896fd3419f168243ff6acbd08b0bd20b3e
MD5 8e54496ee0020eada2c9f95fb5a0f27d
BLAKE2b-256 0f7581c1597f3f3f8a6a4f8c9edd428a13a8d88a85a46c5912c92cc34b0ef32a

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