Changes

Jump to navigation Jump to search
1,323 bytes added ,  17:04, 8 October 2015
temp save
Debugging a PHP application can involve quite a bit of machinery, and effort getting that machinery setup. But it's worth it because what alternative is there? <code>echo</code>? Come on!

== First get Xdebug setup ==
Xdebug is the project for debugging PHP. The [http://xdebug.org/wizard.php wizard] will show you how to upgrade your package version. In my case, the Xdebug packaged for Ubuntu was 2.2.3, but the more recent version is '''2.3.3'''

=== Summary ===
'''Xdebug installed:''' 2.2.3
'''Server API:''' Apache 2.0 Handler
'''Windows:''' no
'''Zend Server:''' no
'''PHP Version:''' 5.5.9-1
'''Zend API nr:''' 220121212
'''PHP API nr:''' 20121212
'''Debug Build:''' no
'''Thread Safe Build:''' no
'''Configuration File Path:''' /etc/php5/apache2
'''Configuration File:''' /etc/php5/apache2/php.ini
'''Extensions directory:''' /usr/lib/php5/20121212+lfs

Caveat: their script can't really tell where the xdebug configuration lives. In Ubuntu, there is a /etc/php5/conf.d and configuration files in there add to the main php.ini. So, you end up editing <code>sudo vim /etc/php5/conf.d/xdebug.ini </code>

Following the sage advice of the [http://wiki.netbeans.org/HowToConfigureXDebug#General_Information Netbeans wiki], you want to get xdebug's '''debugclient''' working on localhost first, then add Netbeans.
4,558

edits

Navigation menu