How can I find out where exit or die is called from in a PHP script

I have a PHP script that hooks Wordpress (through wp-load.php) to do different things. For some reason, during a script, after running update_post_meta(in a loop), the script just stops. No errors, exceptions. Nothing.

I registered a shutdown function and was called, so it seems to me that another plugin somehow calls dieor exit. Is there any way to find out where this is called? Maybe some kind of return line?

+4
source share
3 answers

It's impossible. It is not possible to easily and reliably lure die () and exit () into your need to check the date the filter file was modified

0

, die() exit(), php wp. wp true. wp-config.php wordpress. , . .

0

The right way to do this is with an IDE like PHPStorm and PHP debugging tools like Xdebug .

0
source

Source: https://habr.com/ru/post/1626482/


All Articles