WPIntell

Source evidence

Changed .htaccess Debug Lines

Debug Log Manager – Conveniently Monitor and Inspect Errors · support · 2024-12-30T23:51:00+00:00

mixedsentiment
highseverity
0.94relevance
5replies
Evidence linked to opportunitycommercial context

Proof Health

Open evidence

Commercial opportunities need traceable source links before they are treated as build-worthy.

6 / 35 rows with source links

17.1% of this page's analysis has direct source links.

0 build-decision rows missing links

0 rows here require auditable proof before promotion.

29 rows with no attached evidence

0 rows have source counts but still need direct links.

Conversation

support
technoogies resolved
This plugin removed and replaced my debug if statements. ORIGINAL /*** — Turn on WP DEBUG Here — ***/ define( ‘WP_DEBUG’, false ); if (WP_DEBUG) { define( ‘WP_DEBUG_DISPLAY’, true ); // true OR false define( ‘SCRIPT_DEBUG’, true ); // true OR false, force WordPress to use the DEV versions of core CSS and JavaScript files rather than the minified versions define( ‘SAVEQUERIES’, true ); // true causes each query to be saved, how long that query took to execute, and what function called it. } define( ‘WP_DEBUG_LOG’, $sitepath . ‘.hold/wp-errors.log’ ); // Create a hidden folder named .hold After activating the plugin: /*** — Turn on WP DEBUG Here — ***/ if (WP_DEBUG) { // true OR false // true OR false, force WordPress to use the DEV versions of core CSS and JavaScript files rather than the minified versions define( ‘SAVEQUERIES’, true ); // true causes each query to be saved, how long that query took to execute, and what function called it. } // Create a hidden folder named .hold @technoogies Debug Log Manager only directly modifies wp-config.php. It does not touch .htaccess. Perhaps you have something that is trying to sync wp-config.php with .htaccess? You are correct! I miss stated the file name and it is wp-config.php. @technoogies Debug Log Manager does not expect an if statement to be present. Can you remove all the debug-related lines in wp-config.php first? Then try to disable then re-enable debug loggin in Debug Log Manager’s dashboard. All of my sites are set this way. The plugin works regardless of the if statement. Would it pass over it if the entire if statement was commented out? I’ll just need to remember to remove them if not, when activating the plugin. Maybe add a check for if statements in a future release and comment it out automatically, then remove the commented if when disabled? @technoogies I thought debug logging was broken / not working. If it works, then that’s OK I guess. It’s just that toggling debugging on / off in Debug Log Manager will probably not restore your wp-config.php as it was with the if statement. I will probably not make any change in Debug Log Manager to compensate for an edge case like yours. Fiddling with wp-config.php programmatically is rather tricky. It’s been working fine as is for 5,000+ installs so far, so, I’ll leave it as is for now if you don’t mind. Thanks again for reporting the issue in details.

Comments

5 shown
Bowo 2025-01-02T14:02:00+00:00

@technoogies Debug Log Manager only directly modifies wp-config.php. It does not touch .htaccess. Perhaps you have something that is trying to sync wp-config.php with .htaccess?

technoogies 2025-01-02T21:05:00+00:00

You are correct! I miss stated the file name and it is wp-config.php.

Bowo 2025-01-03T02:07:00+00:00

@technoogies Debug Log Manager does not expect an if statement to be present. Can you remove all the debug-related lines in wp-config.php first? Then try to disable then re-enable debug loggin in Debug Log Manager’s dashboard.

technoogies 2025-01-03T02:20:00+00:00

All of my sites are set this way. The plugin works regardless of the if statement. Would it pass over it if the entire if statement was commented out? I’ll just need to remember to remove them if not, when activating the plugin. Maybe add a check for if statements in a future release and comment it out automatically, then remove the commented if when disabled?

Bowo 2025-01-03T03:13:00+00:00

@technoogies I thought debug logging was broken / not working. If it works, then that’s OK I guess. It’s just that toggling debugging on / off in Debug Log Manager will probably not restore your wp-config.php as it was with the if statement. I will probably not make any change in Debug Log Manager to compensate for an edge case like yours. Fiddling with wp-config.php programmatically is rather tricky. It’s been working fine as is for 5,000+ installs so far, so, I’ll leave it as is for now if you don’t mind. Thanks again for reporting the issue in details.