1.vscode 安装PHP Debug扩展;
2.php环境配置:
1.安装xdebug扩展:

  sudo apt-get install php-xdebug

    2.找到扩展的路径:
    chq@chq-Ubuntu:/usr/bin$ find /usr/ -name "xdebug.so"
    /usr/lib/php/20151012/xdebug.so

    3.编辑php.ini文件,末尾加入,保存退出:
    chq@chq-Ubuntu:/usr/bin$ find /usr/ -name "xdebug.so"
    /usr/lib/php/20151012/xdebug.so
    在php.ini后面补充:

[xdebug]
zend_extension="/usr/lib/php/20151012/xdebug.so"
xdebug.remote_enable=1
xdebug.remote_autostart = 1
xdebug.remote_handler=dbgp
xdebug.remote_mode=req
xdebug.remote_host=127.0.0.1
xdebug.remote_port=9000

相关文章:

  • 2022-12-23
  • 2021-06-01
  • 2021-08-08
  • 2022-12-23
  • 2022-01-15
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-07-28
  • 2022-01-02
  • 2021-08-19
  • 2021-09-03
  • 2022-12-23
相关资源
相似解决方案