简体   繁体   中英

PHP intl extension not loading after enabling it

Just when I tried to use the NumberFormatter class in my code which requires the php intl extension in order to use the class. I enabled the extension by un-commenting it in the php.ini configuration file but still won't work. I changed this

;extension=intl

to this

extension=intl

but still doesn't work even after restarting my server.

I found a way to do that which works for me. What I did is to copy the all the files containing this name icu****.dll from my php directory into the Apache bin directory then restart my server.

The icu****.dll files are up to 4 in my own php directory. I tried this using php version 7.4.9

To see the loaded extensions, run the code below on your server.

<?php
$extensions = get_loaded_extensions();
print_r($extensions);
?>

The solution was got from this github issue

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