作者:陈业贵 华为云享专家 51cto(专家博主 明日之星 TOP红人) 阿里云专家博主

文章目录


注意:

想要在phpstorm中调试请满足一个条件。那就是安装在d盘。为什么呢?因为这样方便复制粘贴呀,
要开启phpstudy中的php扩展的xdebug啊

第一步:phpstudy里面的php.ini中:复制粘贴

[Xdebug]
xdebug.default_enable=On
xdebug.idekey = "PHPSTORM"
zend_extension=D:/phpstudy_pro/Extensions/php/php7.3.4nts/ext/php_xdebug.dll
xdebug.collect_params=1
xdebug.collect_return=1
xdebug.auto_trace=On
xdebug.trace_output_dir=D:/phpstudy_pro/Extensions/php_log/php7.3.4nts.xdebug.trace
xdebug.profiler_enable=On
xdebug.profiler_output_dir ="D:\phpstudy_pro\Extensions\tmp\xdebug"
xdebug.remote_enable=On
xdebug.remote_host=127.0.0.1
xdebug.remote_port=9100
xdebug.remote_handler=dbgp

第二步:phpstorm中

phpstorm—>File----》settings---->languages&Frameworks---->php---->debug—>

phpstorm安装xdebug(phpstudy环境下)成功运行_服务器


phpstorm安装xdebug(phpstudy环境下)成功运行_服务器_02

phpstorm安装xdebug(phpstudy环境下)成功运行_复制粘贴_03

点击这两个,先点击apply再点击ok.

phpstorm安装xdebug(phpstudy环境下)成功运行_php_04

第三步:phpstorm中

phpstorm安装xdebug(phpstudy环境下)成功运行_服务器_05


phpstorm安装xdebug(phpstudy环境下)成功运行_php扩展_06


phpstorm安装xdebug(phpstudy环境下)成功运行_php_07

第四步:phpstorm中

phpstorm安装xdebug(phpstudy环境下)成功运行_php_08


phpstorm安装xdebug(phpstudy环境下)成功运行_php_09

第五步:phpstorm中

phpstorm安装xdebug(phpstudy环境下)成功运行_复制粘贴_10

phpstorm安装xdebug(phpstudy环境下)成功运行_phpstorm_11

phpstorm安装xdebug(phpstudy环境下)成功运行_复制粘贴_12


phpstorm安装xdebug(phpstudy环境下)成功运行_php扩展_13


phpstorm安装xdebug(phpstudy环境下)成功运行_php扩展_14

完成!!!