PDT + Xdebug 调试 PHP
Jun 23, 2016 pm 02:33 PM
环境:
PHP Version 5.2.9-1
Apache 2.2.11
PDT(PHP Development Tools)
http://www.eclipse.org/pdt/downloads/
下载pdt all-in-ones,我下的版本是pdt-all-in-one-win32-2.0.0GA.zip
http://www.xdebug.org/download.php
下载xdebug,对应的php版本,由于我的是php5.2.9
xdebug没有对应的5.2.9。所以选择5.2.5或者5.2.8(之前下过5.3.0,没有配置成功)
php_xdebug-2.0.3-5.2.5.dll 或 php_xdebug-2.0.4-5.2.8.dll
将xdebug放进C:\Program Files\PHP\ext目录
修改php.ini配置,加入xdebug的配置信息:
[Xdebug]
;extension=php_xdebug-2.0.3-5.2.5.dll ;这里可是花了大半天的时间,无法调试断点,断点不起作用,Xdebug必须得使用zend_extension_ts来挂载
zend_extension_ts="C:/Program Files/PHP/ext/php_xdebug-2.0.3-5.2.5.dll"
xdebug.auto_trace = On
xdebug.show_exception_trace = On
xdebug.remote_autostart = On
xdebug.remote_enable = On
xdebug.collect_vars = On
xdebug.collect_return = On
xdebug.collect_params = On
xdebug.trace_output_dir="c:/Program Files/PHP/debuginfo" ;这个目录默认是没有的,必须手动去创建
xdebug.profiler_output_dir="c:/Program Files/PHP/debuginfo"
重启apache,具体调试方式可参考下面链接:
玩转PHP调试:PHP Debug

Hot Article

Hot tools Tags

Hot Article

Hot Article Tags

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics

11 Best PHP URL Shortener Scripts (Free and Premium)

Working with Flash Session Data in Laravel

Build a React App With a Laravel Back End: Part 2, React

Simplified HTTP Response Mocking in Laravel Tests

cURL in PHP: How to Use the PHP cURL Extension in REST APIs

12 Best PHP Chat Scripts on CodeCanyon
