referer:http://www.javashuo.com/article/p-qgwtbqyb-ne.html
https://xdebug.org/download.phpphp
phpstorm+phpstudy 动态调试环境,phpstorm安装参考:http://www.javashuo.com/article/p-zizinhbb-go.html
phpstudy2016自带xdebug扩展,不过php.ini不大同样,要对照着参数改改。浏览器
安装phpstudy后,开启php扩展 xdebug框架
对照修改php.iniphpstorm
[XDebug] xdebug.profiler_output_dir="D:\phpStudy\tmp\xdebug" xdebug.trace_output_dir="D:\phpStudy\tmp\xdebug" zend_extension="D:\phpStudy\php\php-5.6.27-nts\ext\php_xdebug.dll" xdebug.auto_trace=on xdebug.collect_params=on xdebug.collect_return=on xdebug.profiler_enable=on xdebug.remote_enable = on xdebug.remote_handler = dbgp xdebug.remote_host= 127.0.0.1 xdebug.remote_port = 9000 xdebug.idekey = PHPSTORM
安装 phpstorm 和配置 有点繁琐:ide
文件->设置->语言和框架->PHP功能的 project Configuraction url
默认在 PHP language level 中会自动选择当前的php版本, CLI Interpreter 须要手工建立下,选择下 php.exe 路径:debug
文件->设置->语言和框架->PHP->debug 调试
文件->设置->语言和框架->PHP->debug->DBGp Proxy,这里配置的和 php.ini 文件的主机和端口要一致,若是有冲突则换个端口code
而后导航栏里面点 编辑结构->建立一个并配置server 就是当前http服务, 还有默认监听的浏览器,以下:orm
输入须要调试的url
而后点 第二个 蓝色的 调试 按钮, 就出来了。