zend studio调试

XDdebug搞了我一天

先把php.ini的代码发一下

[XDebug] 
zend_extension = "d:/WAMP/wamp/bin/php/php5.5.12/zend_ext/php_xdebug-2.2.5-5.5-vc11-x86_64.dll" 
;是否开启远程调试  
xdebug.remote_enable = 1  
;是否开启调试内容  
xdebug.profiler_enable = 1  
;开启远程调试自动启动  
xdebug.remote_autostart = 0  
;开启自动跟踪  
xdebug.auto_trace = 1  
;调试插件dbgp  
xdebug.remote_handler = "dbgp"  
;允许调试的客户端IP  
xdebug.remote_host = "localhost"  
;远程调试的端口  
xdebug.remote_port = 19000  
xdebug.idekey= "ECLIPSE_DBGP"  
;调试输出路径  
xdebug.profiler_output_dir = "D:\xdebug"  
xdebug.remote_log = "D:\xdebug\remote.log"  
;跟踪输出路径  
xdebug.trace_output_dir = "D:\xdebug"  
;开启异常跟踪  
xdebug.show_exception_trace = 1  
;是否收集变量  
xdebug.collect_vars = 1  
;是否收集返回值  
xdebug.collect_return = 1  
;是否收集参数  
xdebug.collect_params = 1  
;显示局部变量  
xdebug.show_local_vars = 1  
;显示默认的错误信息  
xdebug.default_enable = 1  
xdebug.profiler_enable_trigger = 0  

 很多人配置了也不能正常debug,有一部分人是因为端口问题

我这里用的是19000,我遇到的不是,我用的是集成环境,当phpinfo显示有XDebug时说明是安装成功的

但是在调试之前,点击wamp,找到php->php setting ,其中有三个XDebug的选项,都开启就行了

 

今天又出了些问题,大概是把目录换了下吧

换了目录之后,一定要重新配置下,不然没有效果

另外,我发现wamp下加载的php.ini是在apache下的php.ini

所以要去apche下的php.ini进行配置,文件夹下搜索下就能找到了

xdebug.remote_enable = On
xdebug.profiler_enable = On
xdebug.profiler_enable_trigger = On
xdebug.remote_port = 19000
xdebug.auto_trace = On
xdebug.profiler_output_name = cachegrind.out.%t.%p
xdebug.profiler_output_dir = "D:/WAMP/wamp/tmp"
xdebug.show_local_vars=On

posted @ 2017-03-22 15:53  安筱雨  阅读(387)  评论(0编辑  收藏  举报