Overview of Key Topics

Debugging is hard, and it can be a nightmare to figure out what’s wrong with your website. It may seem like the best option would be to use WordPress’s debug tool but if you’re running an online store that has customers browsing all of the time then this could pose some risks for them as well. Instead, create a new log file so you don’t have any issues while trying to find where things went wrong on your site!

Enabling DEBUG mode

  • Log into your server via SSH or FTP.
  • Edit the wp-config.php file using SSH or your FTP client.
  • Near the bottom of the file you’ll see the following:
define('WP_DEBUG', false);

Adjust that line to these three lines:

define( 'WP_DEBUG', true );
define( 'WP_DEBUG_DISPLAY', false );
define( 'WP_DEBUG_LOG', true );

Important Reminder

It’s not recommended to change WP_DEBUG_DISPLAY. This is because any errors will then display on your live website. By enabling WP-DEBUG LOG, you can view the same errors in your /wp-content/debug.log file

When an error is thrown in WordPress, it will write to a file titled debug.log.

This file is located on your /wp-content/ directory and can be opened up using SSH or FTP for easy viewing of the report that contains all details about the current state of code execution.

When errors occurred during runtime by going through every line from start to finish with log messages at each step along the way until either success was achieved or failure has been reached as well as debugging information such as date-time stamps, user logs, etcetera!