Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Symfony2 : How to make the php_intl extension available for Symfony2?

I'm trying to follow this documentation on Symfony : http://symfony.com/doc/current/book/forms.html

ok so here is my thing, I've externalised my form and created a specific form class for handling the process and being able to reuse it.

So what happen when I submit the form, whatever the info are okay or not for my class, I get this fatal Error :

Fatal error: Call to a member function setAttribute() on a non-object in C:\Program Files (x86)\wamp\www\QNetworks\vendor\symfony\src\Symfony\Component\Form\Extension\Core\DataTransformer\NumberToLocalizedStringTransformer.php on line 130 Call Stack

I'm running with php 5.3.9 and my intl extension is installed and activated BUT when I run the app/check.php command I see :

[[WARNING]] Checking that the intl extension is available: FAILED

* Install and enable the intl extension (used for validators) *

So I don't understand what the problem with this extension. Should I reinstall it ? When I go here : http://php.net/manual/en/intl.requirements.php I see tht i can install the PECL or the ICU library, but i don't know if I should and if there is any relation with my problem ..

like image 750
Miles M. Avatar asked Jun 27 '12 21:06

Miles M.


1 Answers

Your Intl extention must be configured propertly. Check on your server if this really activated using phpinfo()

then on your php.ini activate logging:

[intl]
intl.error_level = E_WARNING
extension=php_intl.dll

and check logs

If it's activated maybe it's a malfunction. Try to redownload the dll into c:\PHP\ext\php_intl.dll

like image 90
Chopchop Avatar answered Dec 28 '22 13:12

Chopchop