FeaturesPluginsDocs & SupportCommunityPartners

NetBeans Forums

 FAQFAQ   SearchSearch   MemberlistMemberlist   RegisterRegister   ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
  

New guy to NetBeans Debugger
Goto page 1, 2  Next
 
Post new topic   Reply to topic    NetBeans Forums -> PHP Users
View previous topic :: View next topic  
Author Message
williamrouse



Joined: 19 Mar 2009
Posts: 26
Location: Minneapolis MN

PostPosted: Fri Mar 20, 2009 12:09 am    Post subject: New guy to NetBeans Debugger Reply with quote

As a new NetBeans user I am working my way through the tutorial and I am unable to get the debugger to work. A prompt appears at the bottom right of the screen saying it is trying to connect to xdebug and is unable to do so. --- Waiting For Connection( netbeans-xdebug). The page then runs through without hitting any of the breakpoints.
First is here is my configuration:
Product Version: NetBeans IDE 6.5.1 (Build 200903060201)
Java: 1.6.0_12; Java HotSpot(TM) Client VM 11.2-b01
System: Windows XP version 5.1 running on x86; Cp1252; en_US (nb)
Running on Windows Vista
Using PHP 5.2.8

Second question:
I am uncertain that I placed the correct xdebug DLL file or files to be found. On the Xdebug site I found six files and placed the 3 that were thread safe, but I am not sure I am placing the correct one but from the name I think it is a good guess. Here are the lines I placed in php.ini file per the tutorial:

zend_extension_ts="C:\PHP5\modules\php_xdebug-2.0.4-5.2.8.dll"
xdebug.remote_enable=1
xdebug.remote_host=localhost
xdebug.remote_port=9000
xdebug.remote_handler=dbgp

Thank you
WBR
Back to top
View user's profile Send private message Visit poster's website
williamrouse



Joined: 19 Mar 2009
Posts: 26
Location: Minneapolis MN

PostPosted: Fri Mar 20, 2009 1:44 am    Post subject: Reply with quote

Problem solved. I found an error where two lines were joined and I can debug now.
Back to top
View user's profile Send private message Visit poster's website
brianb



Joined: 20 Mar 2009
Posts: 4

PostPosted: Fri Mar 20, 2009 3:22 pm    Post subject: Reply with quote

I have the same problem you have stated. However, I don't understand what you did to fix the problem. could you explain further what change you made? Thanks.
Back to top
View user's profile Send private message
williamrouse



Joined: 19 Mar 2009
Posts: 26
Location: Minneapolis MN

PostPosted: Fri Mar 20, 2009 4:01 pm    Post subject: Reply with quote

What I can offer is the addition I added to my php.ini file.
Code:

[XDebug]
;; Only Zend OR (!) XDebug
;If your installation follows the default settings, PHP processing will be enabled automatically.
;To attach XDebug to the PHP engine, locate the php.ini file and add the following lines to it:
;For a thread-safe PHP engine:
;zend_extension_ts="<path to the php folder>/php_xdebug-<version-number>.dll" xdebug.remote_enable=1
zend_extension_ts="C:\PHP5\modules\php_xdebug-2.0.4-5.2.8.dll"
xdebug.remote_enable=on
xdebug.remote_handler=dbgp
xdebug.remote_host=localhost
;; Port number must match debugger port number in NetBeans IDE Tools > Options > PHP  -- YES
xdebug.remote_port=9000

xdebug.profiler_enable=1
xdebug.profiler_output_dir="C:\temp\php"
xdebug.show_local_vars=on


The changes I made to my system was to create the directory in my PHP directory and added the debug file with the correct version number that I downloaded from the Xdebug site.
I then created a second directory for the xdebug profiler output.

I then stopped the Apache server and restarted it. If there are any errors in the file it will be noted when you restart the server.
I hope that helps.
Back to top
View user's profile Send private message Visit poster's website
brianb



Joined: 20 Mar 2009
Posts: 4

PostPosted: Fri Mar 20, 2009 5:11 pm    Post subject: Reply with quote

Thanks for the response. I added the following lines

xdebug.profiler_enable=1
xdebug.profiler_output_dir="C:\temp\php"
xdebug.show_local_vars=on

to my php.ini file and set

xdebug.remote_enable=on

instead of

xdebug.remote_enable=1

but it still doesn't work. I think the =1 may be for Linux installations. It's kind of hard to tell from the installation instructions. Anyway, I entered more details about my problem at

http://forums.netbeans.org/viewtopic.php?t=10062&highlight=

Thanks for the assistance.
Back to top
View user's profile Send private message
slo_town



Joined: 01 Apr 2009
Posts: 5

PostPosted: Wed Apr 01, 2009 10:56 pm    Post subject: Waiting For Connection (netbeans-xdebug) on CentOS system Reply with quote

My problem with xdebug is similar but it is on a CentOS 5 installation
NetBeans 6.5.1
XDebug 2.0.4
Apache 2.2.3

I get the message "Waiting For Connection (netbeans-xdebug)" and it waits forever.

I followed the installation instructions in the XDebug README.
When I do "php -m" from the command line, XDebug is not listed.

In php.ini (the only php.ini in the system), I have the ff lines:

zend_extension="/usr/lib/php/modules/xdebug.so"

[Debug]
xdebug.remote_enable = On
xdebug.remote_handler = dbgp
xdebug.remote_host =localhost
xdebug.remote_port = 9000

I've also restarted httpd.

Any ideas?
Back to top
View user's profile Send private message
williamrouse



Joined: 19 Mar 2009
Posts: 26
Location: Minneapolis MN

PostPosted: Wed Apr 01, 2009 11:13 pm    Post subject: Reply with quote

Not really although on non-windows system I would try:
xdebug.remote_enable = 1

When you run phpinfo() do you see a xdebug section? I guess that is the same as “php –m”, is it not?

I also added these three lines but they should make no difference:
xdebug.profiler_enable=1
xdebug.profiler_output_dir="C:\temp\php"
xdebug.show_local_vars=on
Back to top
View user's profile Send private message Visit poster's website
slo_town



Joined: 01 Apr 2009
Posts: 5

PostPosted: Thu Apr 02, 2009 12:03 am    Post subject: Reply with quote

I don't see xdebug when I run phpinfo();
Back to top
View user's profile Send private message
williamrouse



Joined: 19 Mar 2009
Posts: 26
Location: Minneapolis MN

PostPosted: Thu Apr 02, 2009 12:14 am    Post subject: Reply with quote

Did you try 1 instead of on?

I also remember seeing a note about the an incompatability between the Java version being used on Unix systems and NetBeans.

I don't have good advice for you.
Back to top
View user's profile Send private message Visit poster's website
slo_town



Joined: 01 Apr 2009
Posts: 5

PostPosted: Thu Apr 02, 2009 12:22 am    Post subject: Reply with quote

Yes, I tried setting xdebug.remote_enable = 1

Thanks for replying. At least, someone is listening.
Back to top
View user's profile Send private message
slo_town



Joined: 01 Apr 2009
Posts: 5

PostPosted: Thu Apr 02, 2009 5:49 pm    Post subject: xdebug.ini shows up in phpinfo() Reply with quote

After paying more attention to the comments (see below) in the php.ini file, I created a xdebug.ini file:

;;;;
; Note: packaged extension modules are now loaded via the .ini files
; found in the directory /etc/php.d; these are loaded by default.
;;;;

However, neither phpinfo() nor "php -m" shows xdebug as a PHP extension nor a Zend extension.
phpinfo() lists xdebug.ini in additional .ini files parsed.
Back to top
View user's profile Send private message
williamrouse



Joined: 19 Mar 2009
Posts: 26
Location: Minneapolis MN

PostPosted: Thu Apr 02, 2009 7:42 pm    Post subject: Reply with quote

You found this in the php.ini file?
;;;;
; Note: packaged extension modules are now loaded via the .ini files
; found in the directory /etc/php.d; these are loaded by default.
;;;;

What version of PHP are you using?
Back to top
View user's profile Send private message Visit poster's website
slo_town



Joined: 01 Apr 2009
Posts: 5

PostPosted: Thu Apr 02, 2009 8:32 pm    Post subject: Reply with quote

I am using
PHP 5.2.9
zend 2.2.0
xdebug 2.0.4
Back to top
View user's profile Send private message
williamrouse



Joined: 19 Mar 2009
Posts: 26
Location: Minneapolis MN

PostPosted: Thu Apr 02, 2009 9:10 pm    Post subject: Reply with quote

I assume from the first note you wrote earlier today things are not working so let me ask a couple of questions.
In the following line you are using a file called "php_xdebug-2.0.4-5.2.9.dll"
Code:

;For a thread-safe PHP engine:
;zend_extension_ts="<path to the php folder>/php_xdebug-<version-number>.dll"
zend_extension_ts="C:\PHP5\modules\php_xdebug-2.0.4-5.2.8.dll"

If so where did you find that module, just curiouse.
[/code]
Back to top
View user's profile Send private message Visit poster's website
Jeff Rubinoff
Posted via mailing list.





PostPosted: Mon Apr 06, 2009 3:25 pm    Post subject: New guy to NetBeans Debugger Reply with quote

slo_town,
Just checking that the php.ini file you edited was the one shown in
Configuration File when you run phpinfo().
And that your zend_extension_ts points to the correct location.
And that you are indeed using the thread-safe xdebug version.
I don't know why you created an xdebug.ini. To my knowledge, all
settings are in php.ini.

Jeff

slo_town wrote:
Quote:
Yes, I tried setting xdebug.remote_enable = 1



Thanks for replying. At least, someone is listening.










Back to top
Display posts from previous:   
Post new topic   Reply to topic    NetBeans Forums -> PHP Users All times are GMT
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
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
You can attach files in this forum
You can download files in this forum


Powered by phpBB