Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Symfony 2: Install and enable the intl extension

I'm using XAMPP for Windows and decided to try out Symfony 2.

As soon as I get to Symfony Configuration page it recommends me to install and enable intl.

I tried reading PEAR's and PECL's guides, since I'm total 0 on this topic(started learning PHP recently), but nothing worked.

I found php_intl.dll inside my C:\xamp\php\ext. The php.ini's extension_dir= is set to "C:\xampp\php\ext". I was only missing the extension=php_intl.dll inside php.ini, so I added it.

Unfortunately it didn't work, and Symfony keeps asking me for intl.

like image 723
Bob Avatar asked Apr 18 '12 21:04

Bob


4 Answers

Follow these steps:

  1. Copy all the file names starting with "icu" from C:\wamp\bin\php\php5.5.12 and paste to C:\wamp\bin\apache\apache2.4.9\bin (I am using WAMP. Figure it out yourself for XAMP.)

You can try. Nothing will harm. If you feel the things are not working, you can delete them. I am sure it will work for you 100%.

  1. Uncomment the following line on C:\wamp\bin\apache\apache2.4.9\bin\php.ini

    extension=php_intl.dll
    

It will work.

like image 124
srbhattarai Avatar answered Nov 04 '22 12:11

srbhattarai


http://php.net/manual/en/intl.requirements.php

This extension is bundled with PHP as of PHP version 5.3.0. Alternatively, the PECL version of this extension may be used with all PHP versions greater than 5.2.0 (5.2.4+ recommended).

also read my comment to your post above

like image 44
Hajo Avatar answered Nov 04 '22 12:11

Hajo


Whenever you make changes to php.ini, remember to restart Apache. Otherwise the changes won't take effect. You can do this in the XAMPP Control Panel by clicking the stop/start button in the Apache module row.

like image 11
ThomasPeeters Avatar answered Nov 04 '22 13:11

ThomasPeeters


For Linux users: Installing php5-intl made it work for me

sudo apt-get install php5-intl

found here: http://www.php.net/manual/en/intl.setup.php

like image 3
Julian Orinyol Avatar answered Nov 04 '22 13:11

Julian Orinyol