详情页

idea配置php的xdebug调试

时间:2024年04月22日

编辑:佚名

1.修改php.ini
;extension=php_xdebug  如果有这段代码就把这段代码注释了<br>
[XDebug]
zend_extension="H:/phpstudy_pro/Extensions/php/php7.3.4nts/ext/php_xdebug.dll"
xdebug.remote_enable=true
xdebug.remote_host=localhost
xdebug.remote_port=9001
xdebug.remote_connect_back=1
;下面两项和Intellij idea里的对应
;xdebug.idekey=11105
xdebug.idekey=py
xdebug.remote_handler=dbgp
xdebug.remote_mode=req
;下面这句很关键,不设置intellij idea无法调试
xdebug.remote_autostart=1
;调试配置,详细的可以参考phpinfo页面进行配置
xdebug.auto_trace=on
xdebug.collect_params=on
xdebug.collect_return=on
xdebug.trace_output_dir="../xdebug"
xdebug.profiler_enable=on
xdebug.profiler_output_dir="../xdebug"
xdebug.collect_vars=on
xdebug.cli_color=on
 ;设置变量显示的相关参数
xdebug.var_display_max_children=128
xdebug.var_display_max_data=51200
xdebug.var_display_max_depth=10
2.设置php版本与php.exe运行路径

3.配置Debug的端口,填写9001,要与php.ini里面的端口一致。

4.设置DBGp Proxy的参数IDE key,  Host,   Port,参数与php.ini一致。

5.设置Servers的参数,服务器的Name,Host,Port。

  

 

 

 

 

 

 

 
相关文章
猜你需要