无为清净楼资源网 Design By www.qnjia.com
一. 准备
1.1 下载 xdebug
我本地用的是 phpStudy 的集成环境, php 版本是 7.2.10
在 Xdebug 下载地址(https://xdebug.org/download/historical)找到合适的版本(这边包含历史版本),我选的是 PHP 7.2 VC15 (32 bit)
1.2 配置 PHP
将下载好的文件放入 php 下的 ext 文件夹内,以我本机为例 (E:\Castle\phpStudy\PHPTutorial\php\php-7.2.1-nts\ext)
php.ini 拉到最下面,加上以下内容
[XDebug] xdebug.profiler_output_dir="E:\Castle\phpStudy\PHPTutorial\tmp\xdebug" xdebug.trace_output_dir="E:\Castle\phpStudy\PHPTutorial\tmp\xdebug" zend_extension="E:\Castle\phpStudy\PHPTutorial\php\php-7.2.1-nts\ext\php_xdebug-2.9.5-7.2-vc15-nts.dll" xdebug.remote_enable = 1 xdebug.remote_handler = dbgp xdebug.remote_host = "localhost" xdebug.remote_mode = req xdebug.remote_port = 9010 xdebug.idekey="PHPSTORM" xdebug.remote_autostart = 1
1.3 打印 phpinfo() 页面
看 Xdebug 是不是已经有了,如果没有一般都是下载的版本错了
二. PhpStorm 配置
2.1 Settings 处的配置
2.1.1 从 File > Settings,输入 PHP,红框处的就是我们需要配置的地方
2.1.2 先配置一下 PHP 的版本(我本地用的 7.2,)
2.1.3 Debug port 这边的值用之前在 php.ini 里面新增的值,其它不动
2.1.4 DBGp Proxy 这边的值也使用之前 php.ini 里面新增的
2.1.5 配置 Servers (到这边为止设置里面就配置完毕了)
2.2 新增 debug 配置
2.2.1 从箭头处进入,选择 PHP Web Page 新建
2.2.2 配置完毕
三. 举例说明
3.1 在前面打上断点,正常就会出现如下内容啦
3.2 postman 请求 (基本没有区别,唯一要注意的就是 2.1.5 配置 Servers 这边的 Host 配置了,你的请求域名是什么就填什么就可以了)
总结
无为清净楼资源网 Design By www.qnjia.com
广告合作:本站广告合作请联系QQ:858582 申请时备注:广告合作(否则不回)
免责声明:本站文章均来自网站采集或用户投稿,网站不提供任何软件下载或自行开发的软件! 如有用户或公司发现本站内容信息存在侵权行为,请邮件告知! 858582#qq.com
免责声明:本站文章均来自网站采集或用户投稿,网站不提供任何软件下载或自行开发的软件! 如有用户或公司发现本站内容信息存在侵权行为,请邮件告知! 858582#qq.com
无为清净楼资源网 Design By www.qnjia.com
暂无评论...
更新日志
2024年09月25日
2024年09月25日
- 江玲.1989-这样你才爱我,是吗?【新作有声】【WAV+CUE】
- 郭美美.2010-我是郭美美【华纳】【WAV+CUE】
- 黄心懋1991-轻忧郁【滚石】【WAV+CUE】
- 群星.2000-大地金曲世纪回顾2CD【大地】【WAV+CUE】
- 王菲.1996-浮躁(2024环球MQA-UHQCD限量版)【环球】【WAV+CUE】
- 群星.2022-传家电视剧原声带【东阳欢娱】【FLAC分轨】
- 《摇滚教父 伍佰黄金精选 2CD》 [WAV+CUE][1GB]
- 《凤凰传奇 我从草原来》[WAV/分轨][400MB]
- 《叶倩文 真心真意过一生》[WAV+CUE][400MB]
- 潘越云.1985-世间女子(滚石25周年经典复刻版)【滚石】【WAV+CUE】
- 陈柏宇.2009-CANT.BE.HALF【SONY】【WAV+CUE】
- 李明依.1989-小女生【滚石】【WAV+CUE】
- 《李荣浩 新时代创作新人王》[WAV分轨][310MB]
- 《黑鸭子与马头琴 史上最动听草原音乐》[WAV+CUE][320MB]
- 《汽车发烧音乐精选CD18》[FLAC+CUE][7.1G]