php5.4+xdebug

网上说5.4版本配置xdebug会有错,可能是因为版本对应的问题,的确很难配对,下面是我配置5.4成功的记录:

1:下载php

    使用的是php-5.4.8-Win32-VC9-x86.zip版本, 下载地址:http://windows.php.net/download/

2: 下载xdebug

    使用版本:Xdebug 2.2.1   PHP 5.4 VC9 (32 bit)  ,解压放到php根目录下的ext文件夹,下载地址:http://xdebug.org/download.php

3:修改php.ini

    

zend_extension="E:/work/Server/PHPCore/ext/php_xdebug-2.2.1-5.4-vc9.dll"			;载入Xdebug

[Xdebug]											;xdebug配置

xdebug.profiler_enable=on
xdebug.trace_output_dir="E:/work/Server/PHP_XDebug"       					;xdebug 的数据文件目录

xdebug.profiler_output_dir="E:/work/Server/PHP_XDebug"    					;xdebug 的数据文件目录

xdebug.auto_trace = On										;开启自动跟踪
xdebug.show_exception_trace = On								;开启异常跟踪
xdebug.remote_autostart = On									;开启远程调试自动启动
xdebug.remote_enable = On									;开启远程调试
xdebug.remote_handler=dbgp                							;用于zend studio远程调试的应用层通信协议

xdebug.remote_host=127.0.0.1              							;允许连接的zend studio的IP地址

xdebug.remote_port=9000                  							;反向连接zend studio使用的端口
xdebug.collect_vars = On									;收集变量
xdebug.collect_return = On									;收集返回值
xdebug.collect_params = On									;收集参数
xdebugbug.max_nesting_level = 10000          							;如果设得太小,函数中有递归调用自身次数太多时会报超过最大嵌套数错

 

4:修改zend studio的默认调试器

   Window -> Preferences -> PHP -> Debug  将左侧 "Default Settings" 中的 "PHP Debugger" 设置为 "XDebug"

 

5: 使用phpinfo测试,如果出现如下图则成功:

   


 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值