I'm debugging a PHP process using xdebug CLI.
I can attach to the process and set up breakpoints using breakpoint_set
. However, they need to be set each time and cannot be defined on the code itself.
Is there any way to set a breakpoint in code? Something like debugger
in JavaScript? That is, I do not want to set the breakpoints in the IDE by clicking on the left, this is what all guides suggest.
CodePudding user response:
I have plans to make the dbgpClient
that you mention, remember breakpoints that have been set through it. I haven't had the time to implement that yet.
For now, you can use the xdebug_break()
function to interrupt the execution flow, and make the debugger pause.