Sunday, January 20, 2008

How To Install Xdebug (PHP Web Server Debugger) In Ubuntu Linux

As I mentioned from my previous blog, a how to in web development in Linux (September 2007), you just download the Eclipse IDE package in Zend. This package contains the zend debugger for debugging PHP scripts, but for a web server, you may use zend or xdebug.

Here is how to install xdebug:
1.In Synaptic: Install php-pear and php5-dev
2.In terminal: #sudo pecl install xdebug
3.Add these 2 lines to php.ini:

zend_extension="(path to xdebug.so)"
xdebug.remote_enable=1

4.In Eclipse, click “debug” icon->Open Debug Dialog->PHP Web Page->New->choose Xdebug in Server Debugger.

That's it!