views:

1073

answers:

4

I'm using Zend Studio to do remote debugging of my php scripts on a dev server. It works great for web code, but can I make it work with command line scripts?

I have several helper apps to make my application run. It would be really useful to fire up the remote debugger through command line instead of a web browser so I can test these out.

I assume it's possible, since I think Zend is using xdebug to talk to Eclipse. Apparently, it adds some parameters to the request to wake the Zend code up on a request. I'm guessing I'd need to tap into that?

UPDATE

I ended up using xdebug with protoeditor over X to do my debugging.

+1  A: 

Since this is more along the lines of product support, your best bet is probably emailing the support people. We bought Zend Studio at my last job and they were always able to help us in a matter of hours.

Feel free to post the answer though, I am sure there are more people looking for it. :)

Till
+1  A: 

There's an option to debug a php script, run->run as->php script

I believe it also has to be in your project root though. Just for clarification, Zend studio uses their own debugger, while the eclipse pdt project you have the option for Xdebug or Zend's debugger.

Brendon
+1  A: 

I was able to get remote CLI debugging working in Eclipse, using xdebug, though I've not tried it with the zend debugger. I would assume this should work the same with ZSfE, if that's the "Zend Studio" you're using.

A: 

Haven't tried, but you can set the QUERY_STRING environment variable to the one that toggles the Zend debugger on.

Per this article.

export QUERY_STRING=start_debug=1&debug_host=<host name or IP of the local machine>&debug_port=<the port that is configured in your ZDE settings>&debug_stop=1

And then run the CLI script.

Ramon Poca