前言
工要善其事,必先利其器
在开发过程中我们经常需要debug来调试我们的程序,但很多小伙伴对于如何在phpStorm上开启debug不是很清楚,于是只能通过var_dump打印信息来调试
因为上个月重装了系统,环境需要重新搭建,索性就整理一篇文章
准备工作
电脑php开启XDebug
我使用的是Mac版的MAMP,只需要在MAMP中开启即可

如果是自己单独安装的php或其它方式请大家自行下配置XDebug
开始
- 打开项目点击添加配置

- 点击加号找到
php web page

- 随便输入一个name后点击server

- 新建一个server,信息为你本地服务器的信息

- 点击OK后返回来点击validate,全绿则成功

- 最后点击如图的小电话开启监听

测试
- 最后我们点击调试按钮运行一下项目试试

- 成功进入断点

结束
感谢你的阅读,希望本文对你有所帮助
下载看看
I drop a comment whenever I like a article on a site or I have something to valuable to contribute to the discussion. Usually it is a result of the fire displayed in the article I looked at. And on this article Freewind主题音乐播放器(老王重制版) - 冷文学习者. I was actually excited enough to post a comment :-) I actually do have a few questions for you if it's okay. Could it be just me or do some of these responses appear like left by brain dead people? :-P And, if you are posting at other places, I would like to keep up with everything new you have to post. Could you list the complete urls of your communal sites like your linkedin profile, Facebook page or twitter feed? Feel free to surf to my blog post :: https://bonusstats.com/en/bonus-7signs
Thanks for finally talking about >Freewind 1.5 更新 - 冷文学习者
下载看看
我要回复一下课件