Skip to main content



      Home
Home » Language IDEs » PHP Development Tools (PDT) » Debugging a project with html, js and php files(Debugging a project with html, js and php files)
Debugging a project with html, js and php files [message #549807] Wed, 28 July 2010 00:17 Go to next message
Eclipse UserFriend
I have a project containing the files index.html, javascript.js, and server.php

The index.html file includes the javascript file, which uses Ajax to call server.php (using the POST method).

The goal is to debug the php code.

Is there any place where I can read what debug configurations I should be using? The following is my experience thus far:

when I right-click on the project, then do Debug As | Debug on Server, I get a dialog to select the server type, in which I make the following choices:

Server type = HTTP Server
Server's host name = localhost
Server name = http server at localhost
Server runtime environment = http server

Then, when I click finish, I get a dialog saying that the server is not in debug mode. I choose the "switch mode" option, then click OK.

However the debugger does not start, and the breakpoints in the PHP code are ignored.

Any suggestions will be appreciated. Most useful will be a pointer to detailed configuration instructions.

-sameer
Re: Debugging a project with html, js and php files [message #550065 is a reply to message #549807] Wed, 28 July 2010 22:50 Go to previous messageGo to next message
Eclipse UserFriend
OK, some progress ... there are some fairly detailed instructions given here: http://robsnotebook.com/php_debugger_pdt_xdebug

I followed them quite carefully, but when I try to launch the debug session, the debugger does not start. Instead, when I look at the "progress" view, I see "Launching : waiting for Xdebug session"

However, phpinfo shows that Xdebug seems to have been configured properly.
Re: Debugging a project with html, js and php files [message #550113 is a reply to message #550065] Thu, 29 July 2010 03:41 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: dkel50.hotremovemail.com

Go to the PDT documentation section at
http://www.eclipse.org/pdt/docs.php

and read the PDT 2.0 XDebug Guide for more help.

Dave

On 29/07/2010 03:50, Sameer wrote:
> OK, some progress ... there are some fairly detailed instructions given
> here: http://robsnotebook.com/php_debugger_pdt_xdebug
>
> I followed them quite carefully, but when I try to launch the debug
> session, the debugger does not start. Instead, when I look at the
> "progress" view, I see "Launching : waiting for Xdebug session"
>
> However, phpinfo shows that Xdebug seems to have been configured properly.
Re: Debugging a project with html, js and php files [message #551046 is a reply to message #550113] Wed, 04 August 2010 21:38 Go to previous message
Eclipse UserFriend
Thanks for the suggestion.

My problem was that the page from which I was beginning the debugging, index.html, had been created as an html file (since it did not have any php code in it).

When I created it as a php file, index.php, then everything worked well. So it seems that even files which contain only html should actually be created as php files.

Regards.

Previous Topic:How to display parameter when you key in function
Next Topic:using libcurl code in eclipse
Goto Forum:
  


Current Time: Mon May 12 18:34:36 EDT 2025

Powered by FUDForum. Page generated in 0.03208 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top