Warning: Can't synchronize with repository "(default)" (Unsupported version control system "svn": No module named svn). Look in the Trac log for more information.

Changes between Version 2 and Version 3 of GzipCompressing


Ignore:
Timestamp:
07/06/07 10:55:13 (12 years ago)
Author:
Chris Arndt
Comment:

migration notice

Legend:

Unmodified
Added
Removed
Modified
  • GzipCompressing

    v2 v3  
    1 [[PageOutline]] 
    2  
    3 == Gzip Compressing Content == 
    4  
    5 You can setup Turbogears to compress all the data it sends to the web browser using a cherrypy filter called GzipFilter. If you are serving a lot of text based content, you will probably want this enabled to save bandwidth and to provide a much faster loading experience to the users. You can enable this by editing config/app.cfg file: 
    6  
    71{{{ 
    8 [/] 
    9 gzip_filter.on = True 
    10 gzip_filter.mime_types = ["application/x-javascript", "text/javascript", "text/html", "text/css", "text/plain"] 
     2#!rst 
     3.. note:: This page has been migrated to http://docs.turbogears.org/.0/RoughDocs/GzipCompressing. 
    114}}} 
    12  
    13 Note that if mime_types isn't specified, the gzip filter defaults to ["text/html", "text/plain"]. 
    14  
    15 In the above example we only gzip javascript, css and html content. Images and other binary files are left out as they are usually pre-compressed (jpg, gif, etc.)