From 0d45adf78c1e9cd468b24122d1f8bccfdc253a97 Mon Sep 17 00:00:00 2001 From: kristineds Date: Sat, 21 May 2016 17:28:52 +0800 Subject: [PATCH] Fix conditional and update description; See: websharks/comet-cache#754 --- src/includes/classes/MenuPageOptions.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/includes/classes/MenuPageOptions.php b/src/includes/classes/MenuPageOptions.php index 55b6bef5..18c1a033 100644 --- a/src/includes/classes/MenuPageOptions.php +++ b/src/includes/classes/MenuPageOptions.php @@ -697,7 +697,7 @@ public function __construct() echo '
'."\n"; - if (is_multisite() && $this->plugin->applyWpFilters(GLOBAL_NS.'_exclude_hosts_option_enable', is_multisite())) { + if ($this->plugin->applyWpFilters(GLOBAL_NS.'_exclude_hosts_option_enable', is_multisite())) { // Display option panel for Host Exclusion Patterns. echo ' '."\n"; @@ -706,10 +706,11 @@ public function __construct() echo '
'."\n"; echo '

'.__('Don\'t Cache These Special Host Exclusion Patterns?', SLUG_TD).'

'."\n"; - echo '

'.__('Sometimes there are certain cases where a particular file, or a particular group of files, should never be cached. This is where you will enter those if you need to (one per line). Searches are performed against the HTTP_HOST; i.e., /path/?query (caSe insensitive). So, don\'t put in full URLs here, just word fragments found in the file path (or query string) is all you need, excluding the http:// and domain name. A wildcard * character can also be used when necessary; e.g., /category/abc-followed-by-* (where * = 0 or more characters that are NOT a slash /). Other special characters include: ** = 0 or more characters of any kind, including / slashes; ^ = beginning of the string; $ = end of the string. To learn more about this syntax, please seeĀ this KB article.', SLUG_TD).'

'."\n"; + echo '

'.__('If there are specific domains that should not be cached, you can enter them here so they are excluded automatically. The easiest way to exclude a host is to enter the full domain name on a line of it\'s own in the field below.', SLUG_TD).'

'."\n"; + echo '

'.__('This field also supportsĀ Watered-Down Regex syntax, which means that you can also exclude a pattern like: *.example.com or *.example.*. So for instance, if you wanted to exclude all child sites and only cache pages on the Main Site of a Network installation, you could exclude all sub-domains using: *.mynetwork.com. That excludes anything.mynetwork.com, but not mynetwork.com by itself.', SLUG_TD).'

'."\n"; + echo '

'."\n"; - echo '

'.__('Tip: let\'s use this example child site that uses a sub-domain: http://www.child-blog.main.com. To exclude this child site, you would put this line into the field above: www.child-blog.main.com. Or, you could also just put in a small fragment, like: ^child-blog.*$ and that would exclude any host containing that word fragment.', SLUG_TD).'

'."\n"; echo '

'.__('Note: please remember that your entries here should be formatted as a line-delimited list; e.g., one exclusion pattern per line.', SLUG_TD).'

'."\n"; echo '
'."\n"; }