How can I install intl PHP extension in PHP 7.1.7, which is delivered with osx high sierra?
After the integration from brew/php to brew/core, the intl extension is included by the default installation. I also had the same problem the intl extension wasn't working. The problem I had was the command-line environment was not using the installed version of PHP but the default version from macOS system.
To enable the installed version, you need to do this:
After
brew install php@7.1
You need to link the installed PHP version by
brew link php@7.1
Then you need to OPEN A NEW TERMINAL to make it effective.
Then double check the PHP binary path,
which php
make sure it's
/usr/local/bin/php
instead of
/usr/bin/php
Then check if the intl extension is enabled,
php -m | grep intl
It works for me.