在学习php的时候,如果直接报错没有debug,排错过程是很痛苦的。所以配置了一下phpstrom的debug。步骤下面会为大家详细带来。
1. 打开wamp的php.ini文件,将3个enable配置项打开:
[xdebug]
zend_extension ="D:/wamp/bin/php/php5.6.35/zend_ext/php_xdebug-2.5.5-5.6-vc11.dll"
xdebug.remote_enable = 1
xdebug.profiler_enable = 1
xdebug.profiler_enable_trigger = 1
xdebug.profiler_output_name = cachegrind.out.%t.%p
xdebug.profiler_output_dir ="D:/wamp/tmp"
xdebug.show_local_vars=0
xdebug.remote_port=9000
xdebug.remote_host= localhost
2. 在chrom上安装插件Xdebug helper
3. 配置phpstorm
注:端口号和php.ini配置文件一致
4. 配置server
5. 配置web page
6. 配置服务端
7. 在上一步弹出的窗口进行配置
8. chrom上开启插件的debug模式
9. 运行debug
扫码关注腾讯云开发者
领取腾讯云代金券
Copyright © 2013 - 2025 Tencent Cloud. All Rights Reserved. 腾讯云 版权所有
深圳市腾讯计算机系统有限公司 ICP备案/许可证号:粤B2-20090059 深公网安备号 44030502008569
腾讯云计算(北京)有限责任公司 京ICP证150476号 | 京ICP备11018762号 | 京公网安备号11010802020287
Copyright © 2013 - 2025 Tencent Cloud.
All Rights Reserved. 腾讯云 版权所有