1. Locate ZendDebugger.so or ZendDebugger.dll file that is compiled for the
correct version of PHP (4.3.x, 4.4.x, 5.0.x, 5.1.x, 5.2.x) in the
appropriate directory.
2. Add the following line to the php.ini file:
Linux and Mac OS X: zend_extension=/full/path/to/ZendDebugger.so
Windows: zend_extension_ts=/full/path/to/ZendDebugger.dll
Windows non-tread safe: zend_extension=/full/path/to/ZendDebugger.dll
(*) the windows non-thread safe is used only with Zend Core 2.0
3. Add the following lines to the php.ini file:
zend_debugger.allow_hosts=<ip_addresses>
zend_debugger.expose_remotely=always
4. Place dummy.php file in the document root directory.
5 设置完毕以上事项后,在eclipse中,选择Help-Help Contents-PDT User Guide-Getting Started-Basic Tutorials-Working with the Debugger,请参照此文档学习如何在该环境下调试php代码,需要提醒注意的是在进行php web程序调试的时候,一定要把工程文件复制到apache服务器目录下,并且做好与本地文件之间的对应关系,这样一旦开始进入调试模式,调试器才能找到源代码。