A Django mixin application to raise a registration or paywall
Project description
Django Registration Wall is a Django mixin application that limits an anonymous user’s access to content, after which the user is redirected to the login URL. The behavior is modeled after the common paywall scenario.
Fake news articles credit goes to The Onion.
Install
$ pip install django-registrationwall
Add to settings.py.
INSTALLED_APPS = [
# ...
'regwall',
]
Add to one of your views.py.
from django.views.generic import DetailView
from regwall.mixins import RaiseRegWallMixin
from .models import Article
class ArticleDetailView(RaiseRegWallMixin, DetailView):
model = Article
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
Built Distribution
File details
Details for the file django-registrationwall-0.1.5.tar.gz
.
File metadata
- Download URL: django-registrationwall-0.1.5.tar.gz
- Upload date:
- Size: 3.4 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | df166d5d287d0f0be4ece13ac0640796312e2c5a5229afa00501285db391ff88 |
|
MD5 | 634d7eabf4126a8f34c36f15ca899345 |
|
BLAKE2b-256 | 73701d0cf75cbb4c678aea794d701ff4f31bcb3e8c40f7cf8729dfd10c96a9cd |
File details
Details for the file django_registrationwall-0.1.5-py2.py3-none-any.whl
.
File metadata
- Download URL: django_registrationwall-0.1.5-py2.py3-none-any.whl
- Upload date:
- Size: 15.5 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | fbb3e710dada1ac6285a1b4bc5052ab7511f62759bb43eb4e2b79fa19ca32509 |
|
MD5 | 1016cc24e244071fbb77de05398e55ec |
|
BLAKE2b-256 | cb5bc666176b25d3479b54d1e42e79126f34698f8c9dae8ba25664b13ec4c5b1 |