Debug Multiple Files? Help! [message #82550] |
Fri, 24 October 2008 14:49  |
Eclipse User |
|
|
|
Originally posted by: johnywhy.gmail.com
I'm able to debug a single script, but how to step through a php app
containing many files?
When i debug a single php file as a script, it does not seem to find needed
external php files or images.
The debugger does not seem to understand a multi-file application.
If i choose 'debug as web page', Eclipse loads the web site correctly,
including external files, but without any code step-through is available.
I don't need remote debug, just local debug.
Running IIS (i know, i know), and php 4.4.x.
Each php file contains html as well as php script.
Using the Zend debugger.
Help!
|
|
|
|
|
Re: Debug Multiple Files? Help! [message #82675 is a reply to message #82550] |
Mon, 27 October 2008 17:33   |
Eclipse User |
|
|
|
Hi John,
I think the main problem is your understanding of how the debugging
works. You say that you don't need to do remote debugging as it is on
the local machine. Unfortunately "remote" debugging doesn't mean that it
is on another machine. Remote is where the php code is running somewhere
other than inside the Eclipse debugging. In your case the remote
connection is between your Eclipse IDE and the IIS server that is
processing the php files.
Looking at one of the attached screenshots you are running a php script
debug session. This type of debugging will only debug the current script
and any included files until it reaches the end of the php code. Having
redirects and such on web pages don't work from that script based debugging.
You were saying that you couldn't step through your code when you set it
up as a "PHP Web Site". Most likely the reason for this is that the path
configuration for your server was not mapped properly. Unfortunately I
don't know all the correct terms for all of this as I have only done it
with XDebug and a LAMP environment. Best thing would be to continue to
try and get debugging working with it setup as a "PHP Web Page". If you
want to debug multiple files make sure you enable the "multisession"
option within the server configuration of the debug information.
As a note when setting up the server configuration within the Eclipse
Debug... you will want to setup the server location as your full
http://cc/ccproject212 and then make sure your path mapping is setup so
that wherever that ccproject212 directory is on the machine is entered
as the path.
Hopefully that gets you back on track to getting your debugging setup.
--
Shawn Clark
exquisitus wrote:
> I'm able to debug a single script, but how to step through a php app
> containing many files?
> When i debug a single php file as a script, it does not seem to find
> needed external php files or images.
> The debugger does not seem to understand a multi-file application.
>
> If i choose 'debug as web page', Eclipse loads the web site correctly,
> including external files, but without any code step-through is available.
>
> I don't need remote debug, just local debug.
> Running IIS (i know, i know), and php 4.4.x.
>
> Each php file contains html as well as php script.
> Using the Zend debugger.
>
> Help!
|
|
|
Re: screen shots [message #82733 is a reply to message #82661] |
Mon, 27 October 2008 20:43   |
Eclipse User |
|
|
|
I've never gotten anything useful from the Browser Output. Either use the
internal web browser, or an external browser. The internal browser works
quite well, but you don't get Firebug, FirePHP, or Selenium...
I'm using xdebug, so not sure about Zend Debug.
Cheers,
David
exquisitus wrote:
> Attached are a couple screen shots, which will describe my Eclipse question.
> Basically, the page does not look normal during debug, as if it cannot find
> external files/images/pages.
> Submit returns blankindex.php
> Thanks much!
|
|
|
|
Re: PHP Executable? [message #83054 is a reply to message #82918] |
Mon, 03 November 2008 15:03  |
Eclipse User |
|
|
|
exquisitus wrote:
> thanks much for the great feedback, Shawn. now i just have to figure out
> how to do what you are recommending.
> if i have "debugger" set to xdebug, then "php executable" says "none
> defined".
> if i choose zend debugger, then executable lists PHP 4.4.7 and 5.2.5 CGI
> and CLI. not sure which to pick.
> i'm running php 4.4.6 on IIS.
>
The php executable doesn't matter on this page per say as the executable
is whatever the webserver has setup for the php extension. The only time
the executable option is important is if you are working with php
scripts directly and not through a web server. Personally I found XDebug
fairly straight forward but again I have never played with the Zend
Debugger but you should select the same debugger that is setup on the
web server which looked like Zend Debugger from your phpinfo().
--
Shawn Clark
|
|
|
Powered by
FUDForum. Page generated in 0.05624 seconds