문제

I'm a newbie with IDEs, I used Eclipse so far but more like an fancy text editor. I now switched to Netbeans and set it up for Joomla extension development, for which I followed the steps in various tutorials.
Everything works great except debugging. I set up xdebug and it works if I have breakpoints in the Joomla index.php file, but breakpoints in the php files of my component (for example in on e of the model functions) were just ignored.

My setup:
Joomla 2.5
Netbeans 7.4
XAMPP 3.1
xdebug

도움이 되었습니까?

해결책

In both eclipse and netbeans, a prerequisite for debugging is that the project is built.

"Building" doesn't do anything real: php code is not compiled. But it allows the IDE to build a dependency tree, validate the code, allow code completion and follow execution flow from one class to the next.

To build, in eclipse either right click on the project or choose Project/Build from the menu. I have set Build automatically so the resources stay in sync while I work:

enter image description here

다른 팁

I encountered with the same problem, but solution is rather tricky. Actually netbeans stops on breakpoints but no all lines are eligible for breaking. When you put breakpoint wait a little, if beside green square there appears black arrow pointing down then it is OK, otherwise try some other line.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top