\documentclass[a4paper, 11pt]{article}
\renewcommand{\familydefault}{\sfdefault}
\usepackage{a4wide}
\usepackage[utf8]{inputenc}
\usepackage[ngerman]{babel}
\usepackage{color}
\usepackage{graphicx}
\usepackage{setspace}
\usepackage{ulem}
\usepackage{listings}
\usepackage{float}
\usepackage[rflt]{floatflt}
\usepackage{tabularx}
\setlength{\parindent}{0pt}
\title{.htaccess: Komprimierung aktivieren}
\usepackage[
pdftitle={.htaccess: Komprimierung aktivieren}
pdfsubject={GZIP Komprimierung falls vom Clientüber den HTTP-Header akzeptiert in der .htaccess für den Apache Webserver aktivieren}
pdfauthor={Udo Schmal}
pdfkeywords={}
]{hyperref}
\definecolor{darkblue}{rgb}{0,0,.5}
\hypersetup{pdftex=true, colorlinks=true, breaklinks=true, linkcolor=darkblue, menucolor=darkblue, pagecolor=darkblue, urlcolor=darkblue}
\begin{document}.htaccess: Komprimierung aktivieren
\singlespacing
{\Large \textbf{\label{sec:headline}.htaccess}}

\singlespacing
{\LARGE \textbf{\label{sec:title}Komprimierung aktivieren}}

GZIP Komprimierung falls vom Clientüber den HTTP-Header akzeptiert in der .htaccess für den Apache Webserver aktivieren.

In der folgenden Konfiguration wird berücksichtigt ob der Client (Browser) laut seinem HTTP-Header ein Encoding (gzip/deflate) unterstützt, falls der Content-type dann noch DEFLATE unterstützt wird er komprimiert und dem Response HTTP-Header die Info über das Encoding hinzugefügt.\newline

\begin{lstlisting}[breaklines]\# Deflate Compression by FileType
\&lt;IfModule mod\_deflate.c\&gt;
  \#Force compression for mangled headers.
  \&lt;IfModule mod\_setenvif.c\&gt;
    \&lt;IfModule mod\_headers.c\&gt;
      SetEnvIfNoCase \textasciicircum(Accept-EncodXng|X-cept-Encoding|X\{15\}|\textasciitilde\{15\}|-\{15\})\$ \textasciicircum((gzip|deflate)\textbackslashs*,?\textbackslashs*)+|[X\textasciitilde-]\{4,13\}\$ HAVE\_Accept-Encoding
      RequestHeader append Accept-Encoding \&quot;gzip,deflate\&quot; env=HAVE\_Accept-Encoding
    \&lt;/IfModule\&gt;
  \&lt;/IfModule\&gt;
  \# Compress all output labeled with one of the following MIME-types
  \# (for Apache versions below 2.3.7, you don't need to enable `mod\_filter`
  \# and can remove the `\&lt;IFModule mod\_filter.c\&gt;` and `\&lt;/IFModule\&gt;` lines
  \# as `AddOutputFilterByType` is still in the core directives).
  \&lt;IfModule mod\_filter.c\&gt;
    AddOutputFilterByType DEFLATE text/plain
    AddOutputFilterByType DEFLATE text/html
    AddOutputFilterByType DEFLATE text/xml
    AddOutputFilterByType DEFLATE text/css
    AddOutputFilterByType DEFLATE text/javascript
    AddOutputFilterByType DEFLATE application/xml
    AddOutputFilterByType DEFLATE application/xhtml+xml
    AddOutputFilterByType DEFLATE application/rss+xml
    AddOutputFilterByType DEFLATE application/atom\_xml
    AddOutputFilterByType DEFLATE application/javascript
    AddOutputFilterByType DEFLATE application/x-javascript
    AddOutputFilterByType DEFLATE application/x-shockwave-flash
    AddOutputFilterByType DEFLATE application/gpx+xml
    AddOutputFilterByType DEFLATE application/atom+xml
    AddOutputFilterByType DEFLATE application/json
    AddOutputFilterByType DEFLATE application/vnd.ms-fontobject
    AddOutputFilterByType DEFLATE application/x-font-ttf
    AddOutputFilterByType DEFLATE application/x-web-app-manifest+json
    AddOutputFilterByType DEFLATE font/opentype
    AddOutputFilterByType DEFLATE image/svg+xml
    AddOutputFilterByType DEFLATE image/x-icon
    AddOutputFilterByType DEFLATE text/x-component
    AddOutputFilterByType DEFLATE application/font-woff
    AddOutputFilterByType DEFLATE font/woff2
  \&lt;/IfModule\&gt;
\&lt;/IfModule\&gt;\end{lstlisting}
\end{document}