xdebug phpstorm 远程调试PHP

1 linux安装xdebug
pecl install xdebug
zend_extension="/usr/local/php/modules/xdebug.so"
然后php -m 看是否有没安装成功

2 在php.ini中增加
xdebug.idekey=PHPSTORM
xdebug.remote_enable=1
xdebug.remote_host=192.168.10.195 //phpstorm的ip地址
xdebug.remote_port=9000
xdebug.profiler_enable=1
xdebug.profiler_output_dir="/data/log/Xdebug"

3 先设置php的cli运行路径
图片描述

设置xdebug的监听端口,并启动xdebug
图片描述

设置server的相关信息
图片描述

配置php web application的信息
图片描述

然后每次debug都要更换下web application 的地址

然后就可以进行xdebug调试了。


作者: lifeng_881888 
链接:http://www.imooc.com/article/21222
来源:慕课网
发布了45 篇原创文章 · 获赞 5 · 访问量 1万+
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章