Sometimes one needs to use internationalization features in PHP. It might be that a library that you are using depends upon the PHP intl extension. Please note that there are incredibly many ways to accomplish this, so this is merely my way of doing it. Please also note that this article is intended for OS X EI Capitan. I hope this post is useful for you.
We can install PHP intl extension in three simple step:
Macbook comes with ruby pre-installed. So, we can install homebrew just by entering the following command from terminal. For more information on installation, consider reading Homebrew,
$ ruby -e “$(curl -fsSL <a href="https://raw.github.com/Homebrew/homebrew/go/install" rel="nofollow" data-mce-href="https://raw.github.com/Homebrew/homebrew/go/install"> https://raw.github.com/Homebrew/homebrew/go/install</a>)”
Once you have that next step is to keep your dependencies updated. Please note that, this step might be optional in case your all dependent repo are update. Its good practice to keep your repositories updated.
$ brew doctor
Better to update the extensions shown by brew doctor.
The next step is easy and short. You can install intl extension depending upon your requirement. Here, I assume to install PHP70-intall. You have option to choose which one you want to install.
$ brew install php70-intl
$ brew install php56-intl
$ brew install php55-intl
$ brew install php54-intl
I hope this short post is useful to someone in a way or another. If this does not help you might consider reading how to install intl extension on Mavericks