Browse Source

Change Nginx Conf Files

old-stable
Mitesh Shah 12 years ago
parent
commit
7b32e41d5d
  1. 8
      usr/share/easyengine/nginx/wpsingle/w3tc.conf

8
usr/share/easyengine/nginx/wpsingle/w3tc.conf

@ -10,7 +10,7 @@ server {
set $cache_uri $request_uri;
# POST requests and urls with a query string should always go to PHP
# POST Requests And Urls With A Query String Should Always Go To PHP
if ($request_method = POST) {
set $cache_uri 'null cache';
}
@ -19,17 +19,17 @@ server {
set $cache_uri 'null cache';
}
# Don't cache uris containing the following segments
# Don't Cache Uris Containing The Following Segments
if ($request_uri ~* "(/wp-admin/|/xmlrpc.php|/wp-(app|cron|login|register|mail).php|wp-.*.php|/feed/|index.php|wp-comments-popup.php|wp-links-opml.php|wp-locations.php|sitemap(_index)?.xml|[a-z0-9_-]+-sitemap([0-9]+)?.xml)") {
set $cache_uri 'null cache';
}
# Don't use the cache for logged in users or recent commenters
# Don't Use The Cache For Logged In Users Or Recent Commenters
if ($http_cookie ~* "comment_author|wordpress_[a-f0-9]+|wp-postpass|wordpress_logged_in") {
set $cache_uri 'null cache';
}
# Use cached or actual file if they exists, otherwise pass request to WordPress
# Use Cached Or Actual File If They Exists, Otherwise Pass Request To WordPress
location / {
try_files /wp-content/cache/page_enhanced/$http_host/_index.html $uri $uri/ /index.php?$args;
}

Loading…
Cancel
Save