WP Debug

Troubleshooting

WordPress has a built-in debug mode that logs errors to a file instead of displaying them on your site. This is the single most useful tool for diagnosing problems with any WordPress installation, including Monogram.

#Enabling Debug Mode

  1. Connect to your site via FTP/SFTP or your hosting provider file manager
  2. Open the wp-config.php file in your WordPress root directory
  3. Find the line that says /* That's all, stop editing! Happy publishing. */
  4. Add the following lines above that comment:
define('WP_DEBUG', true);
define('WP_DEBUG_LOG', true);
define('WP_DEBUG_DISPLAY', false);
define('SCRIPT_DEBUG', true);
  1. Save the file

Here what each line does:

Constant

Purpose

WP_DEBUG

Turns on debug mode - WordPress starts tracking errors

WP_DEBUG_LOG

Writes errors to /wp-content/debug.log instead of showing them to visitors

WP_DEBUG_DISPLAY

Keeps errors hidden from the front end (set to false for live sites)

SCRIPT_DEBUG

Forces WordPress to load non-minified JS and CSS files for easier debugging

Never leave WP_DEBUG enabled on a production site for extended periods. It can expose sensitive information and slow down your site. Enable it, reproduce the issue, check the log, then disable it.

#Reading the Debug Log

  1. After enabling debug mode, visit the pages where you experience the issue
  2. Open /wp-content/debug.log via FTP or file manager
  3. Scroll to the bottom - the most recent errors appear last
  4. Look for lines that mention monogram, jkd, or plugin names relevant to the issue

A typical error entry looks like this:

[09-Apr-2026 12:34:56 UTC] PHP Fatal error: Uncaught Error: Call to undefined function...
in /wp-content/themes/monogram/functions.php on line 42

The key information is the error type, the file path, and the line number.

#Using SCRIPT_DEBUG with Monogram

The SCRIPT_DEBUG constant is especially useful with Monogram because the theme ships both minified and unminified versions of its assets:

  • assets/js/main.min.js - production (minified, no console output)
  • assets/js/main.js - debug (unminified, with source maps)
  • assets/css/main.min.css - production
  • assets/css/main.css - debug

When SCRIPT_DEBUG is true, WordPress loads the unminified versions, making it much easier to trace JavaScript errors to specific source lines.

#Disabling Debug Mode

Once you've gathered the information you need:

  1. Open wp-config.php again
  2. Change WP_DEBUG to false:
define('WP_DEBUG', false);
  1. You can leave the other three lines in place - they have no effect when WP_DEBUG is false
  2. Optionally, delete the /wp-content/debug.log file to free up space

Before contacting support, enable debug mode and reproduce your issue. Copy the relevant lines from debug.log into your support ticket - it helps the team diagnose the problem much faster.

Last updated

Was this article helpful?

FIND THE ONE THAT FITS YOUR PROJECT

Import a demo, swap the content, adjust the layout. Modern WordPress under the hood, fast even when the site fills up.