How to install Zend Debugger on Windows without Zend Core/Platform

Monday, 28 January 2008

How to install Zend Debugger on Windows without Zend Core/Platform

1. Download

http://downloads.zend.com/pdt/server-debugger/ZendDebugger-5.2.12-cygwin_nt-i386.zip
OR
check for new version at: http://downloads.zend.com/pdt/server-debugger/

Update: 2010-02-09:

for php 5.3+ you will have to download the debugger from
http://www.zend.com/en/products/studio/downloadsand selecting (Studio Web Debugger)

2. Unzip the archive

3. Get debugger from folder called "5_2_x_comp" or you may receive some errors about a non-thread safe debugger if you take it from "5_2_x_nts_comp"

4. Configure debugger by editing your php.ini file

This willl allow connections from local host and from your local network to addresses which start with 192.168.1.

zend_debugger.allow_hosts=127.0.0.1/32, 192.168.1.0/16
zend_debugger.expose_remotely=always


[Zend]
zend_extension_ts="c:/php5/ext/ZendDebugger.dll"

Note:
if you don't have a Zend section you may add this at the end of the fie.
correct the php path if it is not installed in c:\php5 and extension directory.

5. Restart Apache

the command may be
net stop apache2
net start apache2

Note: I am assuming you have Apache2 installed as a service.


You may start debugging with Zend Studio
Tools -> Debug URL -> the url of debugged file

Update (2008-03-04):
To activate the debugger please use following query string:

?start_debug=1&debug_port=10000&debug_fastfile=1&debug_host=192.168.0.2%2C127.0.0.1

Note:

I am assuming that the debugger listens at 192.168.0.2 or 127.0.0.1 on port 10000.

Enjoy.

Slavi

 Digg  Del.icio.us  Reddit  SlashDot

14 comments:

rob said...

Thank you very very much, it helped me a lot! I've spent several days trying to debug and finally I did it :D

Svetoslav Marinov said...

You're welcome Rob.
I am glad it worked for you.

Slavi

Anonymous said...

Very Very useful article. Great job!

Todor Iliev
http://viplord.com

Svetoslav Marinov said...

Thank you my dear cousin Todor for you comment.

Anonymous said...

Спасибо! Очень помогли своей инструкцией!

Svetoslav Marinov said...

Hello Anonymous Russian,
thanks for the comment.
Spasiba

Anonymous said...

Help!!! I think I've read every page out there that talks about configuring Eclipse/PDT/Zend Debugger/Apache-WAMP and cannot get this thing working. Local PHP script debugging works. But I cannot get Apache to connect to the Zend Debugger:

I've used the Eclipse PDT All-In-One package.

Some settings I have:
php.ini:

[Zend]
zend_extension_ts="C:/wamp/bin/php/php5.3.0/ext/ZendDebugger.dll"
zend_debugger.allow_hosts=192.168.1.*, 127.0.0.1
zend_debugger.expose_remotely=always
extension_dir = "c:\wamp\bin\php\php5.3.0\ext"
implicit_flush = On
output_buffering = 0

File system:
Directories c:\wamp\bin\php\php5.3.0 and c:\wamp\bin\php\php5.3.0\ext have the following from ZendDebugger-v5.2-windows-i386.zip (5_2_x_comp) but tried from 5_3_x_nts_comp as well.

ZendDebugger.dll


Put dummy.php in Apache root directory and Doc root directories

I restart things and Apache doesn't show the Zend Debugger loaded:

This program makes use of the Zend Scripting Language Engine:
Zend Engine v2.3.0, Copyright (c) 1998-2009 Zend Technologies


Otherwise, the Apache environment and the Eclipse/PDT environment work just perfect separately.

Any ideas?

Thanks
Carlos

Svetoslav Marinov said...

Hi Carlo,

can you try downgrading the php version.
I have php 5.3 on my dev server and the debugger doesn't work.
I think php 5.2.x should be supported by the debugger.

Slavi

Anonymous said...

Thanks, you're a star!

If it wasn't for your last comment about it not working with 5.3 I could have been messing about for hours.

Svetoslav Marinov said...

Thanks Anonymous!
Take care!

Nitesh Sinha said...

Thanks..Svetoslav for this walkthrough.

i am using php 5.3 in my project , and i found out that php 5.2 or lower does not support some of the features such as "Late Static Bindings" . I have made use of this feature extensively.

Now if i want to try Zend Debugger to debug my application how may i do it with the current php config?

Or do that latest version of zend debugger had started supporting it?

Please let me know if there is any through this.

Nitesh

Svetoslav Marinov said...

Hi Nitesh,

Can you check http://www.zend.com/en/products/studio/downloads and do let me know if Studio Web Debugger works for you.

Slavi

Nitesh Sinha said...

Hi Slavi,

I tried all the workarounds ..
1) using Zend studio web developer
2) downgrading php version to 5.2

i tried with both zend debugger from zend's up date site and from archieve of zend studio web debugger downloaded from the link u gave me.

but still i am not able to start the debugger in eclipse.

can u get me through the walk-through once again...i hope i am not going wrong anywhere..

Svetoslav Marinov said...

Nitesh Sinha,

honestly, I didn't have the time to make the debugger work with php 5.3.
Since, it wasn't urgent I invested in my patience and decided to wait until Zend releases a compatible debugger.

Maybe you could email Zend support and ask for some help in that direction.