Installing PHP xdebug Debugging tools and performance analysis tools Webgrind for Windows

Source: Internet
Author: User
Tags stack trace

Installing PHP xdebug Debugging tools and performance analysis tools Webgrind for Windows

First step : view information such as PHP version

Phpinfo ();

above is x86 NTS VC14

Step two : download xdebug

official website https://xdebug.org/

Step three :

download Extension , add php /ext Extension directory

Fourth Step : php.ini Open Extension

To configure additional options :

[Xdebug]

; Specify Xdebug absolute path to the extension file

zend_extension= "C:\App\php\php\php-7.0.12-nts\ext\php_xdebug-2.7.0alpha1-7.0-vc14-nts.dll"

; maximum number of cycles or debugs , prevent the cycle of death

Xdebug.max_nesting_level=50

; Enable performance detection analysis

Xdebug.profiler_enable=on

; Enable code auto-tracking

Xdebug.auto_trace=on

; allow collection of parameter variables passed to the function

Xdebug.collect_params=on

; allow collection of return values for function calls

Xdebug.collect_return=on

; Specify the storage directory for the stack trace file

Xdebug.trace_output_dir= "C:\App\php\debug"

; Specify a storage directory for profiling files

Xdebug.profiler_output_dir= "C:\App\php\debug"

; Append

Xdebug.profiler_append=1

; Specify the tracking file name format

; xdebug.profiler_output_name = "Cachegrind.out.%c"

Xdebug.profiler_output_name = "cachegrind.out.%s"

; whether remote debugging is turned on

Xdebug.remote_enable = On

; Port

xdebug.remote_port=9000

; Remote Debug Address

Xdebug.remote_host = 127.0.0.1

; Maximum number of layers in an array or object can be set 1023

Xdebug.var_display_max_depth = 10

; will be Require,include relevant loaded file names are written to the trace file

Xdebug.collect_includes=1

; Stack Trace

Xdebug.default_enable=1

; Print Request Method

Xdebug.dump.server=request_method

; Print GET Request Parameters

xdebug.dump.get=*

; Print POST Request Parameters

xdebug.dump.post=*

; Print Cookies

; xdebug.dump.cookie=*

; Print UA

; xdebug.dump.server=http_user_agent

Configure Restart Server

Fifth Step : use

Next, use Xdebug 's log analysis tool to analyze

Xdebug Log Analysis tool webgrind v1.5

: https://github.com/jokkedk/webgrind

After the download, if the compression package decompression ,

Open config.php configuration

static $storageDir = ' C:/app/php/debug '; directory that is configured as xdebug xdebug.profiler_output_dir

after running the test code , visit the Webgrind portal to view

/end

Installing PHP xdebug Debugging tools and performance analysis tools Webgrind for Windows

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.