这篇文章主要介绍了phpstorm断点调试方法,结合图文形式详细分析了phpstorm断点调试的基本配置方法、使用技巧与注意事项,需要的朋友可以参考下
环境:win10+phpstorm2022+phpstudy8+lnmp
1、phpinfo(); 查看是否安装xdebug,没有走以下流程
2、phpstudy中切换不同版本php版本,有些版本不支持xdebug(如php8.0.2),有些已经自带了(如php7.3.9)。已经自带的只需要在php.ini中调用
php.ini 配置文档
[Xdebug] zend_extension=D:/phpstudy_pro/Extensions/php/php7.3.9nts/ext/php_xdebug.dll xdebug.idekey=phpstorm xdebug.remote_enable = On xdebug.remote_host=localhost ;xdebug.remote_port 默认值为9000,这里需要跟phpstorm配置一致,下面有说明 xdebug.remote_port=9000 xdebug.remote_handler=dbgp xdebug.auto_trace = On