Home › Forums › Gutenberg › How to Debug… › Reply To: How to Debug…
When you say that wp debug give no help, you are not seeing PHP errors in the debug log at all?
Or are the coding errors things that do not create an a PHP error (for example in infinite loop that just times out the server) and therefore don’t log errors in the error log?
If it’s the second case, this is always a problem when working with AJAX or REST or whatever you want to popular term is :P, and you need to get some output to see what’s going on. One solution is to log an error yourself.
Some examples:
If I just want to see if my code gets to a specific place before it dies
error_log('Got Here');
let’s say that I want to see what the value of some array is during execution:
ob_start(); print_r($array); error_log(ob_get_clean());
Welcome to the Advanced Custom Fields community forum.
Browse through ideas, snippets of code, questions and answers between fellow ACF users
Helping others is a great way to earn karma, gain badges and help ACF development!
We use cookies to offer you a better browsing experience, analyze site traffic and personalize content. Read about how we use cookies and how you can control them in our Privacy Policy. If you continue to use this site, you consent to our use of cookies.