NuSphere Forums Forum Index
NuSphere Forums
Reply to topic
Using PhpEd debugger with WebOrb PHP


Joined: 27 Aug 2007
Posts: 4
Reply with quote
Hi,
I"m new to PhpEd, trying out the eval. I've been able to debug php code using my local Apache. What I'd love to do is be able to debug classes in PHP that are invoked from WebOrb which is acting as a remoting service for Flex.

This is all local, all under my local root etc. I can write a test php script that uses the class that I've defined as a service, and I can consume it from Flex.

But what I'd like to do, is to have PhpEd sit in debug mode waiting for the script to be called from the outside, so that it would halt at the breakpoint I've set and allow me to debug what's going on.

Is that possible? or is debugging only taking place from the point of view of the PhpEd user going through the path of execution completely within the debugger?
View user's profileFind all posts by jackfreudSend private message
Site Admin

Joined: 13 Jul 2003
Posts: 8344
Reply with quote
I'm not sure what Flex is, what it's written in, and where it runs (remotely to the classes or locally, on the same process or not).
If Flex is a php script/framework and uses the classes as regular php classeses, you don't need to perform any special actions. Just start debugging Flex and all breakpoints you have in the classes will trigger. If you want, you may uncheck "stop on the first line after run" in the debugger settings.
If Flex is a service that runs the classes through a protocol like HTTP or SOAP, you need a way to inform the classes' side that you want to debug them. It can be done with may ways described there http://forum.nusphere.com/howto-run-debug-session-t585.html
Finally, as a last resort, you can put "hardcoded" breakpoint into your code. It can be done with DebugBreak() function call.

_________________
The PHP IDE team
View user's profileFind all posts by dmitriSend private messageVisit poster's website


Joined: 27 Aug 2007
Posts: 4
Reply with quote
Thanks, I'll try that.
Just in case you're interested, Flex is the platform from Adobe (was Macromedia) that lets you create Flash apps in an Eclipse-like IDE (Flexbuilder) to create enterprise and/or commercial applications. Many people are using it with PHP classes acting as middleware on the web server, by way of WebOrb or amfphp. You can see more about Flex at www.flex.org.

Thanks for your help!


dmitri wrote:
I'm not sure what Flex is, what it's written in, and where it runs (remotely to the classes or locally, on the same process or not).
If Flex is a php script/framework and uses the classes as regular php classeses, you don't need to perform any special actions. Just start debugging Flex and all breakpoints you have in the classes will trigger. If you want, you may uncheck "stop on the first line after run" in the debugger settings.
If Flex is a service that runs the classes through a protocol like HTTP or SOAP, you need a way to inform the classes' side that you want to debug them. It can be done with may ways described there http://forum.nusphere.com/howto-run-debug-session-t585.html
Finally, as a last resort, you can put "hardcoded" breakpoint into your code. It can be done with DebugBreak() function call.
View user's profileFind all posts by jackfreudSend private message
Using PhpEd debugger with WebOrb PHP
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
All times are GMT - 5 Hours  
Page 1 of 1  

  
  
 Reply to topic