duduklein
Forum Replies Created
-
Forum: Plugins
In reply to: [Error Log Monitor] Error messages showing up to usersI’m no WP or PHP expert, but in my case, it seems that adding the code to the end of the file was not effective, because the constant WP_DEBUG_DISPLAY was defined in the function wp_initial_constants that was called in the wp-settings file.
As you explained to me that this is a constant and can’t be redefined, once it was defined in that file (and it was set to true), I couldn’t redefine it to false. This seems to be the explanation to me.
Forum: Plugins
In reply to: [Error Log Monitor] Error messages showing up to usersI wrote to my host and they got back to me.
So I had put the code at the end of wp-config.php. They told me that it has to be placed a little bit earlier in the file.
They moved the following part of the code after my code:
/* That's all, stop editing! Happy blogging. */
/** Absolute path to the WordPress directory. */
if ( !defined('ABSPATH') )
define('ABSPATH', dirname(__FILE__) . '/');
/* Fixes "Add media button not working", see https://www.carnfieldwebdesign.co.uk/blog/wordpress-fix-add-media-button-not-working/ */
define('CONCATENATE_SCRIPTS', false );/** Sets up WordPress vars and included files. */
require_once(ABSPATH . 'wp-settings.php');In wp-settings, there is a call to
wp_initial_constants
that is defined inwp-includes/default-constants.php
and has the following code:// Add define( 'WP_DEBUG_DISPLAY', null ); to wp-config.php to use the globally configured setting
// for 'display_errors' and not force errors to be displayed. Use false to force 'display_errors' off.
if ( ! defined( 'WP_DEBUG_DISPLAY' ) ) {
define( 'WP_DEBUG_DISPLAY', true );
}As far as I remember, the plugin instructed me to put the code at the end. Is this wp-settings and default-constants specific to my host ?
Thanks a lot for your time and insights!
- This reply was modified 1 year, 11 months ago by duduklein.
Forum: Plugins
In reply to: [Error Log Monitor] Error messages showing up to usersThanks a lot for all these information. I really appreciate it !
There is no other mention to
WP_DEBUG_DISPLAY
inwp-config.php
, but when I try to remove theif
statement, I get a message saying that the constant was already defined, but I don’t know where.I ran a
grep -sr "WP_DEBUG_DISPLAY" --include *.php .
and got the following :https://drive.google.com/file/d/1eX_u9EL2sQYDOlY9kfccGFcYbXLh6ahC/view?usp=sharing
Isn’t it strange? I’ll contact my host as you suggested.
Forum: Plugins
In reply to: [Error Log Monitor] Error messages showing up to usersIn the “if” statement, we are only checking if WP_DEBUG_DISPLAY is defined should we check if it’s set to true as well, so we can set it to false?
I’m not an php programmer but something like
if ( !defined(‘WP_DEBUG_DISPLAY’) || (WP_DEBUG_DISPLAY == true) ) {
define(‘WP_DEBUG_DISPLAY’, false);
}does it make sense to you?
Forum: Plugins
In reply to: [Error Log Monitor] Error messages showing up to usersThanks for your response.
You understood the situation correctly.
I will keep looking for an explanation
Forum: Plugins
In reply to: [Error Log Monitor] Error messages showing up to usersNo. Both codes were inserted in the same time.
I have even emptied the cache, the issue was resolved and the page was cached again with errors.
Forum: Plugins
In reply to: [Error Log Monitor] Error messages showing up to usersThanks for your quick reply and explanation.
I agree with you that the page with error is being cached. But this page hasn’t changed so why did the version with errors cached in the first place?
If errors are never shown to users, the cached pages should never have errors logs, correct ?
Forum: Plugins
In reply to: [WooCommerce] wc_get_cart_url not returning correct cart url@stuartduff
Is it possible that I had some caching issues for this.I have shut down my computer and restarted it 2h after that and it’s now working as expected!
Thanks for your time and quick support!
Forum: Plugins
In reply to: [WooCommerce] wc_get_cart_url not returning correct cart url@stuartduff , thanks for your response.
I’ll do some tests on my end.
Forum: Plugins
In reply to: [WooCommerce] wc_get_cart_url not returning correct cart urlThanks @stuartduff for yor quick response.
I have set the sites’ pages from WooCommerce > Settings > Advanced as described in the https://docs.woocommerce.com/document/woocommerce-pages/
Is it possible that my thème ovrerides this behavior? I have looked for occurrences of the function’s name in the thème pages and all php files, but can not anything.
Any ideas?
Any news on this topic. I’m also interested.