app/django/views/decorators/gzip.py
author Pawel Solyga <Pawel.Solyga@gmail.com>
Tue, 14 Oct 2008 22:20:55 +0000
changeset 330 2ef48e962655
parent 54 03e267d67478
permissions -rw-r--r--
Add underscore in two word div class names in templates (nick_name, short_name, partial_path). Patch by: Pawel Solyga Review by: to-be-reviewed

"Decorator for views that gzips pages if the client supports it."

from django.utils.decorators import decorator_from_middleware
from django.middleware.gzip import GZipMiddleware

gzip_page = decorator_from_middleware(GZipMiddleware)