search

Home  >  Q&A  >  body text

Enable overloaded var_dump in xdebug.mode=debug

The new Xdebug seems to disable the overloaded var_dump() function in debug mode. I like to use both var_dump() and breakpoint debugging, but I'm forced to use xdebug.mode=develop for var_dump and xdebug.mode=debug for breakpoints Swap back and forth between points.

Is there any way to enable overloaded var_dump() while staying at xdebug.mode=debug?

It's not the end of the world, but it's a little annoying having to swap back and forth when I need a clean var_dump() for a quick analysis.

P粉939473759P粉939473759315 days ago526

reply all(2)I'll reply

  • P粉530519234

    P粉5305192342024-03-30 09:39:54

    You can determine the depth level to dump

    ;try put it 10 or 13 and see the result
    xdebug.var_display_max_depth = 3

    check

    https://xdebug.org/docs/all_settings#var_display_max_depth

    Hope it helps you

    reply
    0
  • P粉195200437

    P粉1952004372024-03-30 00:32:25

    Of course, just list both modes via commas:

    xdebug.mode=debug,develop
    

    Fromhttps://xdebug.org/docs/all_settings#mode

    reply
    0
  • Cancelreply