app/django/views/decorators/gzip.py
author Lennard de Rijk <ljvderijk@gmail.com>
Wed, 26 Nov 2008 16:33:36 +0000
changeset 589 ee9122db04af
parent 54 03e267d67478
permissions -rw-r--r--
Fixes empty spaces appearing in the menu if a person is not allowed to see this menu or if no menu is defined. Patch by: Lennard de Rijk

"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)