APACHE http.conf Rewriterule for deflate

Discussion in 'Apache' started by Stu531, Sep 15, 2009.

  1. #1
    Guys thought you might be able to help me on this:-

    Basics are we need to turn deflate compression off for IE6 SP1 machines (css, js and swf files) but leave deflate on for newer (greater than XP SP1).

    The total browser domain is IE6 and either SP1 (XP) or greater.

    We have been trying to put Rewrite conditions in the IHS >> HTTP.CONF files to cope with it:-

    <Location "/MyApp">
    SetOutputFilter DEFLATE
    AuthType MamCookie
    AuthName MamCookie
    require valid-user
    RewriteEngine On
    RewriteRule (.*)/logoff\.do /MyApp/logon/logonService.do?&mamlogmeout
    RewriteCond %{HTTP_USER_AGENT} .*MSIE\ [6]
    RewriteCond %{HTTP_USER_AGENT} !SV1
    RewriteCond %{REQUEST_URI} \.(css|js|swf)$
    RewriteRule Accept-Encoding: .* $1
    RewriteRule .* $1
    RewriteEngine Off
    </Location>

    The last line does not run and we get a bad flags delimiters error on start up.
    we tried replacing the line with "RewriteRule .* $1 " IHS at least started but it didnt work.

    The code above was a bit of a guess from a few of us down here after hours of web searching.
     
    Stu531, Sep 15, 2009 IP