Turning off debug in my WP blog causes an internal error
Turning off debug in my WP blog causes an internal error
Turning off debug in my WP blog causes an internal error
Ugh, turns our our themes functions.php file had the following directive, overriding all other error reporting. error_reporting(E_ERROR); Moral: Always good to check root theme files if all else fails.
You’re defining WP_DEBUG_LOG twice, first as false and then as true. Doing some very rudimentary testing on my local PHP installation… php > define( ‘X’, true ); php > define( ‘X’, false ); PHP Warning: Constant X already defined in php shell code on line 1 php > print_r( X ); 1 …it seems clear … Read more
I had this line in mu-plugins folder, which was adding the plugin to active list… add_filter(“pre_option_active_plugins”, ‘filter_loaded_plugins’, 10, 2);
Didn’t know that this was already in wp-config.php: if (!defined(‘WP_DEBUG’)) { define(‘WP_DEBUG’, false); } So the define statement I added was indeed redundant. Duh!
This is a shot in the dark, so apologies if i am wrong, but i think i remember having this error code a while ago, and if my memory is correct, running the update on the Updates page instead of the plugins page fixed it for me. Doesnt help for auto updates but might help … Read more
Many big issues in the website, WP_Debug not showing
Something, I do not know what, is resetting my global error_reporting(E_ALL) level to a higher level, thus hiding the errors. Explicitly adding the lower error_reporting in files in question helps show the error.
Concerning your question: Can my theme be submitted for approval with these errors? I’m assuming you’re asking whether your plugin, while throwing an error upon activation using TGM library, can still be submitted and accepted to official WordPress repository. My answer would be, no, it cannot. It seems like you made your plugin work once … Read more
You can use isset() or property_exists() to check if the property exists. foreach ( $taxonomies_password_terms_obj as $taxonomy) { if( isset( $taxonomy->term_id ) ){ $options_password_taxonomies[$taxonomy->term_id] = $taxonomy->name; } }