.htaccess - RewriteEngine On repeating few times -


i have code in .htaccess file can see rewriteengine on repeating few times. can remove of rewriteengine on?

also interested if rest of code wp rocket ok?

# use utf-8 encoding served text/plain or text/html adddefaultcharset utf-8 # force utf-8 number of file formats <ifmodule mod_mime.c> addcharset utf-8 .atom .css .js .json .rss .vtt .xml </ifmodule>  # fileetag none not enough every server. <ifmodule mod_headers.c> header unset etag </ifmodule>  # since we're sending far-future expires, don't need etags static content. # developer.yahoo.com/performance/rules.html#etags fileetag none  <ifmodule mod_alias.c> <filesmatch "\.(html|htm|rtf|rtx|svg|svgz|txt|xsd|xsl|xml)$"> <ifmodule mod_headers.c> header set x-powered-by "wp rocket/2.6.7" header unset pragma header append cache-control "public" header unset last-modified </ifmodule> </filesmatch>  <filesmatch "\.(css|htc|js|asf|asx|wax|wmv|wmx|avi|bmp|class|divx|doc|docx|eot|exe|gif|gz|gzip|ico|jpg|jpeg|jpe|json|mdb|mid|midi|mov|qt|mp3|m4a|mp4|m4v|mpeg|mpg|mpe|mpp|otf|odb|odc|odf|odg|odp|ods|odt|ogg|pdf|png|pot|pps|ppt|pptx|ra|ram|svg|svgz|swf|tar|tif|tiff|ttf|ttc|wav|wma|wri|xla|xls|xlsx|xlt|xlw|zip)$"> <ifmodule mod_headers.c> header unset pragma header append cache-control "public" </ifmodule> </filesmatch> </ifmodule>  # expires headers (for better cache control) <ifmodule mod_expires.c> expiresactive on  # perhaps better whitelist expires rules? perhaps. expiresdefault                          "access plus 1 month"  # cache.appcache needs re-requests in ff 3.6 (thanks remy ~introducing html5) expiresbytype text/cache-manifest       "access plus 0 seconds"  # document html expiresbytype text/html                 "access plus 0 seconds"  # data expiresbytype text/xml                  "access plus 0 seconds" expiresbytype application/xml           "access plus 0 seconds" expiresbytype application/json          "access plus 0 seconds"  # feed expiresbytype application/rss+xml       "access plus 1 hour" expiresbytype application/atom+xml      "access plus 1 hour"  # favicon (cannot renamed) expiresbytype image/x-icon              "access plus 1 week"  # media: images, video, audio expiresbytype image/gif                 "access plus 1 month" expiresbytype image/png                 "access plus 1 month" expiresbytype image/jpeg                "access plus 1 month" expiresbytype video/ogg                 "access plus 1 month" expiresbytype audio/ogg                 "access plus 1 month" expiresbytype video/mp4                 "access plus 1 month" expiresbytype video/webm                "access plus 1 month"  # htc files  (css3pie) expiresbytype text/x-component          "access plus 1 month"  # webfonts expiresbytype application/x-font-ttf    "access plus 1 month" expiresbytype font/opentype             "access plus 1 month" expiresbytype application/x-font-woff   "access plus 1 month" expiresbytype application/x-font-woff2  "access plus 1 month" expiresbytype image/svg+xml             "access plus 1 month" expiresbytype application/vnd.ms-fontobject "access plus 1 month"  # css , javascript expiresbytype text/css                  "access plus 1 year" expiresbytype application/javascript    "access plus 1 year"  </ifmodule>  # gzip compression <ifmodule mod_deflate.c> # active compression setoutputfilter deflate # force deflate mangled headers <ifmodule mod_setenvif.c> <ifmodule mod_headers.c> setenvifnocase ^(accept-encodxng|x-cept-encoding|x{15}|~{15}|-{15})$ ^((gzip|deflate)\s*,?\s*)+|[x~-]{4,13}$ have_accept-encoding requestheader append accept-encoding "gzip,deflate" env=have_accept-encoding # don't compress images , other uncompressible content setenvifnocase request_uri \ \.(?:gif|jpe?g|png|rar|zip|exe|flv|mov|wma|mp3|avi|swf|mp?g)$ no-gzip dont-vary </ifmodule> </ifmodule>  # compress output labeled 1 of following mime-types <ifmodule mod_filter.c> addoutputfilterbytype deflate application/atom+xml \                                   application/javascript \                                   application/json \                                   application/rss+xml \                                   application/vnd.ms-fontobject \                                   application/x-font-ttf \                                   application/xhtml+xml \                                   application/xml \                                   font/opentype \                                   image/svg+xml \                                   image/x-icon \                                   text/css \                                   text/html \                                   text/plain \                                   text/x-component \                                   text/xml </ifmodule> <ifmodule mod_headers.c> header append vary user-agent env=!dont-vary </ifmodule> </ifmodule>  <ifmodule mod_mime.c> addtype text/html .html_gzip addencoding gzip .html_gzip </ifmodule> <ifmodule mod_setenvif.c> setenvifnocase request_uri \.html_gzip$ no-gzip </ifmodule>  <ifmodule mod_rewrite.c> rewriteengine on rewritebase / rewritecond %{https} on rewriterule .* - [e=wpr_ssl:-https] rewritecond %{server_port} ^443$ rewriterule .* - [e=wpr_ssl:-https] rewritecond %{http:accept-encoding} gzip rewriterule .* - [e=wpr_enc:_gzip] rewritecond %{request_method} rewritecond %{query_string} ="" rewritecond %{http:cookie} !(wordpress_logged_in_|wp-postpass_|wptouch_switch_toggle|comment_author_|comment_author_email_) [nc] rewritecond %{request_uri} !^(.*/feed/)$ [nc] rewritecond %{http_user_agent} !^(facebookexternalhit).* [nc] rewritecond "%{document_root}/mounted-storage/wp-content/cache/wp-rocket/%{http_host}%{request_uri}/index%{env:wpr_ssl}.html%{env:wpr_enc}" -f rewriterule .* "/mounted-storage/wp-content/cache/wp-rocket/%{http_host}%{request_uri}/index%{env:wpr_ssl}.html%{env:wpr_enc}" [l] </ifmodule> # end wp rocket  options +followsymlinks rewriteengine on rewritecond %{http_host} ^(www\.)?domain\.org$ [nc] rewriterule ^ http://domain.eu%{request_uri} [l,r=301] # begin wordpress <ifmodule mod_rewrite.c> rewriteengine on rewritebase / rewriterule ^index\.php$ - [l] rewritecond %{request_filename} !-f rewritecond %{request_filename} !-d rewriterule . /index.php [l] </ifmodule> # end wordpress 


Comments

Popular posts from this blog

javascript - jQuery: Add class depending on URL in the best way -

caching - How to check if a url path exists in the service worker cache -

Redirect to a HTTPS version using .htaccess -