基本安裝參考
http://blog.csdn.net/oscar999/article/details/6713666
此部分只是介紹如何在PDT 下如何使用Zend Debugger .php 的web 檔案
1. 解壓下載的Zend Debugger壓縮檔。
1.1) 把5_2_x_comp下的ZendDebugger.dll拷到php安裝目錄(例如 D:\php。 根據php的安裝版本使用對應的ZendDebugger版本)
1.2) 把dummy.php拷到網站根目錄下面(例如: D:\apache2\htdocs)
2. 開啟php.ini,在檔案的最後面加上
[Zend Debugger]
zend_extension_ts="D:/php/ZendDebugger.dll"
zend_debugger.allow_hosts=127.0.0.1
zend_debugger.expose_remotely=allowed_hosts
說明: zend_debugger.allow_hosts最好使用機器的IP地址(可以在cmd 在使用ipconfig /all 查看)
以上Zend debugger安裝完成,可以通過phpinfo函數查看是否安裝成功。
建立phpinfo.php 檔案放在網站目錄下,重啟web server. 訪問這個檔案
<?phpphpinfo();?>
如果找到以下內容, 就說明安裝成功了 (需貼圖)
Zend Engine v2.2.0, Copyright (c) 1998-2010 Zend Technologies
with Zend Debugger v5.2.15, Copyright (c) 1999-2008, by Zend Technologies
接下來就是如何在eclipse 中調試了
1. 點擊bug 表徵圖,選Debug Configurations
2. 雙擊 PHP Web Page--> New_configuration
3. 點configure... 配置正確的IP和連接埠
4. 選需要debug 的File
5. 點擊Test Debugger, 出現 "success"彈出框說明成功了。
6. F6 進行調試