简体   繁体   中英

Problem xcode no work xcode/MAMP/PhpStorm/Mac

I have been through the forums without success. I'm trying to use xcode with PhpStorm on my pimp. I use MAMP/PHP 7.1.19.

When I do a phpinfo() I have nothing about Xdebug.

I have two php.ini files:

-/Applications/MAMP/conf/php7.3.0/php.ini

-/Applications/MAMP/bin/php/php7.3.1/conf/php.ini

I modified both files with:

-zend_extension="/usr/lib/php/extensions/no-debug-non-zts-20160303/xdebug.so"

I have of course check if the file xdebug.so exists.

If the file xdebug.so exists then you have to enable it in the php.ini . At the end of the file you have uncommented the zend_extension but you have to enable it. Add this:

[xdebug]
zend_extension="/Applications/MAMP/bin/php/php7.3.1/lib/php/extensions/no-debug-non-zts-20180731/xdebug.so"
xdebug.profiler_output_dir = "/tmp/xdebug/"
xdebug.remote_autostart=1
xdebug.remote_enable=1
xdebug.remote_log="/usr/local/var/log/httpd/xdebug.log"
xdebug.default_enable=0
xdebug.profiler_enable=0
xdebug.remote_host=localhost
xdebug.remote_port=9000
xdebug.var_display_max_depth=1000

For someone else who doesn't have the xdebug.so file, you have to install the Xdebug extension with PECL. Open the terminal and paste: cd /Applications/MAMP/bin/php/php7.3.1/bin and then install xdebug ./pecl install xdebug

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM