简体   繁体   中英

How to install/enable intl and xsl extensions after installing PHP 7

I installed php7/apache2.4/mysql5.6 via this script , but it turns out that the extensions xsl and intl are missing (need them to run Magento2).

I'm using Ubuntu 14.04.

If it is for dev purposes only, the easiest way would be use a PPA like ppa:ondrej/php-7.0 and then apt-get install php7.0-intl and apt-get install php7.0-xsl . PPAs should NEVER be used in production.

You can run sudo apt-get install php7.0-intl to get it installed. You dont need PPA adding on 16.10 .

1st you need to add ppa repository to server

this can be done by :

sudo add-apt-repository ppa:ondrej/php

when PPA repo installed, update the local package cache by :

sudo apt-get update

after this you need to run following command to install intl & xsl extensions

sudo apt-get install php7.0-intl
sudo apt-get install php7.0-xsl

check the php extensions by :

php -m

if the extension does load on browser , than you need to check your php.ini for apache2

that can be found by calling <?php phpinfo();?> in info.php file

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