debug PHP

php.ini


zend_extension_ts = "c:\wamp\php\ext\php_xdebug-2.0.2-5.2.5.dll"
xdebug.auto_trace = On   
xdebug.collect_params = On
xdebug.collect_return = On
xdebug.trace_output_dir = "d:/debuginfo"
xdebug.profiler_enable = On
xdebug.profiler_output_dir = "d:/debuginfo"
xdebug.remote_enable = true
xdebug.remote_mode = req
xdebug.remote_host = 127.0.0.1
xdebug.remote_port = 19000
xdebug.remote_handler = dbgp

;是否覆盖php里面的函数var_dump();默认是开启的,值为1;设为0,则关闭;
xdebug.overload_var_dump = 1

;WinCacheGrind使用
xdebug.profiler_output_name = "cachegrind.out.%p"



eclipse 配置

[img]http://dl2.iteye.com/upload/attachment/0101/5542/6a5c0c48-b51e-3440-9446-f983ea0bd941.jpg[/img]

[img]http://dl2.iteye.com/upload/attachment/0101/5544/c866dc3e-50e1-36fd-aaa1-67c103ad3917.jpg[/img]

[img]http://dl2.iteye.com/upload/attachment/0101/5548/d306447d-9197-33c5-8ad5-0a7855e90bbb.jpg[/img]

[img]http://dl2.iteye.com/upload/attachment/0101/5550/fbaa1df3-45c5-39d5-9dce-332d5ec20526.jpg[/img]

WinCacheGrind是windows下的profile查看程序。 查看debug信息http://sourceforge.net/projects/wincachegrind

打开WinCacheGrind,将"Tools"=>"Options" =>"Main"的"working flolder" 设置为php.ini中指定的路径xdebug目录。然后刷新一下本地的网页,应该就可以看到下面的监控文件了。

使用 F5 F6 F8调试吧
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值