Skip to main content

Fork of django-url-tracker with query_string support

Project description

django-url-fullpath-redirect
==================

``django-url-fullpath-redirect`` - простой приложение для редиректов в Django. Форк проекта django-url-tracker.
Поддерживает на данный момент следующие коды ответа:
1. 304
2. 410
Редиректы задаются через админку

Установка
------------

Просто::

pip install django-url-fullpath-redirect

Настройка
-------------

Для запуска добавляем в ``settings.py``:

1. Ставим последним в ``MIDDLEWARE_CLASSES`` наше ``url_tracker.middleware.URLChangePermanentRedirectMiddleware``::

MIDDLEWARE_CLASSES = (
'django.middleware.common.CommonMiddleware',
'django.contrib.sessions.middleware.SessionMiddleware',
'django.middleware.csrf.CsrfViewMiddleware',
'django.contrib.auth.middleware.AuthenticationMiddleware',
'django.contrib.messages.middleware.MessageMiddleware',
'django.contrib.flatpages.middleware.FlatpageFallbackMiddleware',
'url_tracker.middleware.URLChangePermanentRedirectMiddleware',
)

2. И добавляем в ``INSTALLED_APPS`` ::

INSTALLED_APPS = (
"url_tracker",
)



Теперь обновляем базу и можем задавать редиректы через админку.
Профит.

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-url-fullpath-redirect, version 0.1.2
Filename, size File type Python version Upload date Hashes
Filename, size django-url-fullpath-redirect-0.1.2.tar.gz (10.2 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page