1. Go to this page and download the library: Download mougrim/php-xdebug-proxy library. Choose the download type require.
2. Extract the ZIP file and open the index.php.
3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
mougrim / php-xdebug-proxy example snippets
return [
'xdebugServer' => [
// xdebug proxy server host:port
'listen' => '127.0.0.1:9002',
],
'ideServer' => [
// if proxy can't find ide, then it uses default ide,
// pass empty string if you want to disable default ide
// defaultIde is useful when there is only one user for proxy
'defaultIde' => '127.0.0.1:9000',
// predefined ide list in format 'idekey' => 'host:port',
// pass empty array if you don't need predefined ide list
// predefinedIdeList is useful when proxy's users aren't changed often,
// so they don't need to register in proxy each proxy restart
'predefinedIdeList' => [
'idekey' => '127.0.0.1:9000',
],
],
'ideRegistrationServer' => [
// host:port for register ide in proxy
// pass empty string if you want to disable ide registration
'listen' => '127.0.0.1:9001',
],
];
...
'softMocks' => [
// if empty string, then vendor/badoo/soft-mocks/src/init_with_composer.php is used
'initScript' => '/your/custom/init-script.php',
],
...