log message for domain mismatch

This commit is contained in:
Peter Molnar 2015-02-02 12:10:15 +00:00
parent 37d3e25cea
commit 1cd2d80e1e
2 changed files with 11 additions and 3 deletions

View file

@ -126,10 +126,11 @@ Version numbering logic:
* every ..C indicates bugfixes for A.B version.
= 1.7.9 =
*2015-01-30*
*2015-02-02*
What's new:
* detailed log messages for other log message clarification
* added auto-upgrade for advanced-cache.php on plugin upgrade

View file

@ -113,10 +113,17 @@ class WP_FFPC extends PluginAbstract {
}
/* set global config key; here, because it's needed for migration */
if ( $this->network )
if ( $this->network ) {
$this->global_config_key = 'network';
else
}
else {
$sitedomain = parse_url( get_option('siteurl') , PHP_URL_HOST);
if ( $_SERVER['HTTP_HOST'] != $sitedomain ) {
$this->errors['domain_mismatch'] = sprintf( __("Domain mismatch: the site domain configuration (%s) does not match the HTTP_HOST (%s) variable in PHP. Please update the settings to match the two, otherwise the plugin may not work as expected.", $this->plugin_constant ), $sitedomain, $_SERVER['HTTP_HOST'] );
}
$this->global_config_key = $_SERVER['HTTP_HOST'];
}
/* cache type possible values array */
$this->select_cache_type = array (