10/19/2008

Add x-debugger-server to the test server

Step:
1 download the x-debugger-server
http://downloads.zend.com/pdt/server-debugger/

2 Locate ZendDebugger.so or ZendDebugger.dll file
that is compiled for the correct version of PHP (4.3.x, 4.4.x, 5.0.x, 5.1.x, 5.2.x) in the
appropriate directory.
("5_2_x_comp" is used for me)

2. Add the following line to the php.ini file:
Linux and Mac OS X: zend_extension=/full/path/to/ZendDebugger.so
Windows: zend_extension_ts=/full/path/to/ZendDebugger.dll
zend_debugger.allow_hosts=
zend_debugger.expose_remotely=always
example:


[Zend]
zend_extension_ts=D:/PHP/ext/ZendDebugger.dll
zend_debugger.allow_hosts=127.0.0.1/32
zend_debugger.allow_tunnel=127.0.0.1/32
zend_debugger.expose_remotely=always

3. Place dummy.php file in the document root directory.
when in ZF project :add the DummyphpController.php to default Module

class DummyphpController extends Core_Controller_Abstract {
public function indexAction() {
@ini_set ( 'zend_monitor.enable', 0 );
if (@function_exists ( 'output_cache_disable' )) {
@output_cache_disable ();
}
if (isset ( $_GET ['debugger_connect'] ) && $_GET ['debugger_connect'] == 1) {
if (function_exists ( 'debugger_connect' )) {
debugger_connect ();
exit ();
} else {
echo "No connector is installed.";
}
}

}
}
?>

4. Restart web server.

No comments: