Problems with phpstorm+xdebug debugging remote code

when making WeChat Mini Programs payment, the callback address must be an address available on the public network, so the code is put on the server.
but when there is something wrong with the callback code, it is very tricky to debug. It is customary to debug code with xdebug breakpoints, so how can you use xdebu to debug remote code?
Environment:
Server centos lamp environment.
A computer in the local local area network. Use the editor phpstorm 2017

referred to a lot of materials on the Internet, but did not achieve success. I hope all the great gods will give us some advice


remote debugging requires that in the machine on which the code is actually running, the xdebug.remote_host and xdebug.remote_port in the php.ini configuration file must be the IP and port number of the machine where the IDE software is located. This is very important.

other references: https://www.cnblogs.com/52fhy.

Menu