@@ -195,11 +195,7 @@ Options -MultiViews
195
195
AddType application/x-font-ttf ttc ttf
196
196
AddType font/opentype otf
197
197
198
- # Make SVGZ fonts work on the iPad.
199
- # https://twitter.com/FontSquirrel/status/14855840545
200
-
201
198
AddType image/svg+xml svg svgz
202
- AddEncoding gzip svgz
203
199
204
200
# Other
205
201
AddType application/octet-stream safariextz
@@ -556,17 +552,34 @@ AddDefaultCharset utf-8
556
552
557
553
# Force compression for mangled headers.
558
554
# https://developer.yahoo.com/blogs/ydn/pushing-beyond-gzipping-25601.html
555
+
559
556
<IfModule mod_setenvif.c >
560
557
<IfModule mod_headers.c >
561
558
SetEnvIfNoCase ^(Accept-EncodXng|X-cept-Encoding|X{15 }|~{15 }|-{15 })$ ^((gzip|deflate)\s*,?\s*)+|[X~-]{4 ,13 }$ HAVE_Accept-Encoding
562
559
RequestHeader append Accept-Encoding "gzip,deflate" env=HAVE_Accept-Encoding
563
560
</IfModule >
564
561
</IfModule >
565
562
566
- # Compress all output labeled with one of the following media types
567
- # (for Apache versions below 2.3.7, you don't need to enable `mod_filter`
568
- # and can remove the `<IfModule mod_filter.c>` and `</IfModule>` lines
569
- # as `AddOutputFilterByType` is still in the core directives).
563
+ # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
564
+
565
+ # Mark certain resources as been compressed in order to:
566
+ #
567
+ # 1) prevent Apache from recompressing them
568
+ # 2) ensure that they are served with the
569
+ # `Content-Encoding: gzip` HTTP response header
570
+
571
+ <IfModule mod_mime.c >
572
+ AddEncoding gzip svgz
573
+ </IfModule >
574
+
575
+ # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
576
+
577
+ # Compress all output labeled with one of the following media types.
578
+
579
+ # IMPORTANT: For Apache versions below 2.3.7 you don't need to enable
580
+ # `mod_filter` and can remove the `<IfModule mod_filter.c>` & `</IfModule>`
581
+ # lines as `AddOutputFilterByType` is still in the core directives.
582
+
570
583
<IfModule mod_filter.c >
571
584
AddOutputFilterByType DEFLATE application/atom+xml \
572
585
application/javascript \
0 commit comments