admin管理员组文章数量:1287979
The link / throws warning when opened on some devices and not on others.
I thought it may be a cahce issue but I have cleared cache from WP-rocket and also browser. Just for the info I am using Plesk web admin tool.
Below is my WP_Config settings
ini_set('log_errors','On');
ini_set('display_errors','Off');
ini_set('error_reporting', E_ALL );
define('WP_DEBUG', false);
define('WP_DEBUG_LOG', true);
define('WP_DEBUG_DISPLAY', false);
The link https://vreqenz-stream.de/shop/ throws warning when opened on some devices and not on others.
I thought it may be a cahce issue but I have cleared cache from WP-rocket and also browser. Just for the info I am using Plesk web admin tool.
Below is my WP_Config settings
ini_set('log_errors','On');
ini_set('display_errors','Off');
ini_set('error_reporting', E_ALL );
define('WP_DEBUG', false);
define('WP_DEBUG_LOG', true);
define('WP_DEBUG_DISPLAY', false);
Share
Improve this question
edited Jun 17, 2019 at 17:05
fuxia♦
107k38 gold badges255 silver badges459 bronze badges
asked Jun 17, 2019 at 17:01
veetragveetrag
111 silver badge2 bronze badges
5 Answers
Reset to default 1Thanks all of you for your response the issue got resolved. The problem was with cached copy of this link https://vreqenz-stream.de/shop/ . I had WP Rocket for caching and apparently it is not doing very good job of purging the cache. I got sure that it is cache issue when I defined the WP_CACHE as false which was true earlier and the warnings disappeared.
Try checking your php.ini file. display_errors may be turned on there and it might be overriding your wp_config file.
There are two constants causing the error: WP_MEMORY_LIMIT
and WP_MAX_MEMORY_LIMIT
, according to the error message I see.
Constants are just that -- 'constant'. They can only be defined once. Once defined, you can't change them. (Cause if you changed them, they wouldn't be 'constant'.)
Check your wp-config.php
file first for duplicate definitions of those. Then check your theme's files (functions.php first, other files next), and plugin files for 'extra' DEFINES
of those constants.
Added
For instance:
DEFINE ($myconstant,"the value");
echo $myconstant; // this is ok
$myconstant = 'new value'; // this will cause an 'already defined' error
One DEFINE for a constant. Use it any way you want, but don't change it.
Some plugins authors turn on error displaying due to inexperience. Try searching for this exact string in wp-content folder.
'error_reporting('
The WP_DEBUG
setting only takes effect when /wp-includes/default-constants.php
is loaded.
You are seeing these errors because they are occurring before that, ie. in wp-config.php
... (which loads wp-settings.php
which then consequently loads /wp-includes/default-constants.php
)
If you want to use define constants multiple times without warnings you would need to check if they are already defined first:
if ( !defined( 'WP_MEMORY_LIMIT' ) ) {define( 'WP_MEMORY_LIMIT', '128M' ); }
Of course only the first definition will be in effect, but this way you won't get the warnings and you can use this to allow for multiple fallback conditions.
But your solution is probably just to simply to check for and remove the multiple definitions, as it's doesn't sound like you are trying to do something more complex like this.
本文标签: cdnWarnings even when the WPDEBUG set to false
版权声明:本文标题:cdn - Warnings even when the WP_DEBUG set to false 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1741335967a2373041.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论