tags:

views:

131

answers:

2

I am using PHP 5.3 on Ubuntu 10.0.4.

I recently upgraded from PHP 5.2 + Netbeans 6.8, where debugging worked fine. Currently, when I am debugging, only SOME variables are available - in some statements (for e.g), where a non-null value is being assigned to a LHS variable, the variable does not appear in the variables window - even though it is clearly in scope.

Has anyone else noticed this behavior - is this a feature or bug?

A: 

me too. and it doesn't break at break points. I am using ubuntu 10.04 too.

==========================================================================

I resolved MY problem: According to the documentation of netbeans, you should add some configuration to php.ini, but this is not the case for Ubuntu 10.04. You should delete everything about xdebug from php.ini and add the configuration in file /etc/php5/conf.d/xdebug.ini:

zend_extension=/usr/lib/php5/20090626+lfs/xdebug.so xdebug.remote_enable = on xdebug.remote_handler = dbgp xdebug.remote_host = localhost xdebug.remote_port = 9000 xdebug.idekey="netbeans-xdebug"

I restarted apache2 and now my break points take effect.

And I didn't notice the problem you mentioned. I am using NetBeans 6.9 + php 5

peter
Thats didn't work (i.e. reported problem remains unresolved). Can you provide a link that shows the changes you recommended?
morpheous
Frankly speaking, I began to debug PHP only a week ago. I did notice that I could see only some of the variables. Compared to the debugging of vs.net, xdebug is too weak.According to netbeans' document, I am supposed to see the value of a variable if I put the cursor over it. But I can't see the value. I am not able to solve your problem. I solved the problem: break points don't break the program.
peter
+2  A: 

The correct answer (i.e. how to fix this) is to be found here: http://phphints.wordpress.com/2010/06/28/local-variables-dont-display-in-netbeans-with-php-5-3-2-and-xdebug-2-0-5/

morpheous