I. Installation of XDEBUG
1, compile and install Xdebug, you can also use pecl install Xdebug
wget http://xdebug.org/files/xdebug-2.3.2.tgz
tar-zxvf xdebug-2.3.2.tgz
cd xdebug-2.3.2
Phpize
./configure--enable-xdebug--with-php-config=/data/php/bin/php-config make
&& make install
Php-config's path must be your Php-config path.
2. Fill in the following stuff into your php.ini
Zend_extension=/alidata/server/php/lib/php/extensions/no-debug-non-zts-20100525/xdebug.so
; Remote settings
xdebug.remote_autostart=on
xdebug.remote_enable=on
xdebug.remote_handler=dbgp
Xdebug.remote_mode=req
xdebug.remote_host=192.168.61.162
xdebug.remote_port=9000
; General
Xdebug.auto_trace=off
xdebug.collect_includes=on
xdebug.collect_params=off
Xdebug.collect_return=off
xdebug.default_enable=on
xdebug.extended_info=1
xdebug.manual_url= Http://www.php.net
xdebug.show_local_vars=0
xdebug.show_mem_delta=0
xdebug.max_nesting_level=
xdebug.idekey=
; Trace options
xdebug.trace_format=0
xdebug.trace_output_dir=/tmp
xdebug.trace_options=0
XDEBUG.TRACE_OUTPUT_NAME=CRC32
; Profiling
xdebug.profiler_append=0
xdebug.profiler_enable=0
xdebug.profiler_enable_trigger=0
xdebug.profiler_output_dir=/tmp
xdebug.profiler_output_name=crc32
xdebug.remote_connect_back = On
Xdebug.idekey = "vagrant"
Precautions:
3.vim Bundle Configuration
~/.VIMRC need to configure this
Plugin ' Joonty/vdebug '
If you install Vundle or VIMRC configuration, you can refer to my other posts.
4.PluginInstall vundleupdate Vundleinstall in the vim low-level command line mode all the time to install a wave
5. Httpd/nginx must reboot to be effective php.ini
6.vim xx.php
7. Press F5
8. At the back of your website, the browser enters
Http://develop.xxx.com/?XDEBUG_SESSION_START=1
9.enjoy
\
Xdebug probably document
Https://mutelight.org/minimal-guide-to-debugging-php-with-xdebug-and-vim
##########
GitHub use documentation for this plugin
Https://github.com/joonty/vdebug