Skip to content

Commit

Permalink
Escaping and pluginkollektiv#200
Browse files Browse the repository at this point in the history
  • Loading branch information
timse201 authored Mar 26, 2021
1 parent 041d60a commit 7dcbf98
Showing 1 changed file with 6 additions and 11 deletions.
17 changes: 6 additions & 11 deletions inc/setup/cachify.hdd.htaccess.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,6 @@
RewriteCond %{HTTPS} off
RewriteRule .* - [E=CACHIFY_HOST:%{HTTP_HOST}]
# set subdirectory
RewriteCond %{REQUEST_URI} /$
RewriteRule .* - [E=CACHIFY_DIR:%{REQUEST_URI}]
RewriteCond %{REQUEST_URI} ^$
RewriteRule .* - [E=CACHIFY_DIR:/]
# gzip
RewriteRule .* - [E=CACHIFY_SUFFIX:]
<IfModule mod_mime.c>
Expand All @@ -35,16 +29,17 @@
</IfModule>
# Main Rules
RewriteCond %{REQUEST_URI} /$
RewriteCond %{REQUEST_METHOD} !=POST
RewriteCond %{QUERY_STRING} =""
RewriteCond %{REQUEST_URI} !^/(wp-admin|wp-content/cache)/.*
RewriteCond %{HTTP_COOKIE} !(wp-postpass|wordpress_logged_in|comment_author)_
RewriteCond %{QUERY_STRING} ^$
RewriteCond %{REQUEST_URI} !^\/(wp\-admin|wp\-content\/cache)\/.*
RewriteCond %{HTTP_COOKIE} !(wp\-postpass|wordpress_logged_in|comment_author)_
RewriteCond ';

$middle = '/cache/cachify/%{ENV:CACHIFY_HOST}%{ENV:CACHIFY_DIR}index.html -f
$middle = '/cache/cachify/%{ENV:CACHIFY_HOST}%{REQUEST_URI}index\.html -f
RewriteRule ^(.*) ';

$ending = '/cache/cachify/%{ENV:CACHIFY_HOST}%{ENV:CACHIFY_DIR}index.html%{ENV:CACHIFY_SUFFIX} [L]
$ending = '/cache/cachify/%{ENV:CACHIFY_HOST}%{REQUEST_URI}index\.html%{ENV:CACHIFY_SUFFIX} [L,NS]
</IfModule>
# END CACHIFY';
?>
Expand Down

0 comments on commit 7dcbf98

Please sign in to comment.