Home >Development Tools >phpstorm >Introducing the configuration of xdebug in PHPSTORM

Introducing the configuration of xdebug in PHPSTORM

藏色散人
藏色散人forward
2021-04-15 14:46:432319browse

The following tutorial column will introduce the configuration of xdebug in PHPSTORM. I hope it will be helpful to friends in need!

xdebug configuration in PHPSTORM

Introducing the configuration of xdebug in PHPSTORMphp configuration: enable xdebug

1. In the php.ini file Add the following configuration options to the xdebug configuration section. The main meaning is to set the address, port number and representation of the phpstorm debugging client, etc.

   xdebug.remote_enable = on 
   xdebug.auto_trace = on
   xdebug.remote_handler=dbgp
   xdebug.remote_host=localhost
   xdebug.remote_port=9000
   xdebug.idekey=PHPSTORM
After the configuration is completed, open phpstorm and set the parser of php. At this time, you should see that the xdebug extension has been installed, otherwise check the configuration file.

#2. Debugging a single PHP file

To debug a single PHP file, you need to configure the DBgp parameters, which can be consistent with the xdebug configuration parameters. As shown below. Introducing the configuration of xdebug in PHPSTORM


After that, select php script in run>edit configurations to debug a single php file.
Introducing the configuration of xdebug in PHPSTORM

The above is the detailed content of Introducing the configuration of xdebug in PHPSTORM. For more information, please follow other related articles on the PHP Chinese website!

Statement:
This article is reproduced at:segmentfault.com. If there is any infringement, please contact admin@php.cn delete