Home >Backend Development >PHP Tutorial >Two methods to install mbstring extension in PHP under Linux system_PHP tutorial

Two methods to install mbstring extension in PHP under Linux system_PHP tutorial

WBOY
WBOYOriginal
2016-07-13 10:40:271907browse

1. Execute

Copy code The code is as follows:

yum install php-mbstring

2. Modify php.ini (this step is very important, some lxadmin versions cannot be modified automatically)

Copy the code The code is as follows:

echo 'extension=mbstring.so' >>/etc/php.ini #Depends on the PHP installation directory

3. Restart web service

If it is apache: service httpd restart


Method 2:
php 5.36
Installation directory: /usr/local/php

Copy the code The code is as follows:

#cd /usr/src/php-5.3.6/ext/mbstring
#/usr/local/php/bin/phpize
#./configure --with-php -config=/usr/local/php/bin/php-config
#make && make install
echo 'extension=mbstring.so' >>/usr/local/php/lib/php.ini
#/usr/local/apache2/bin/apachectl restart

Use /usr/local/php/bin/php -v #Check whether the configuration is wrong
Use php.info to check whether mbstring is installed successfully

www.bkjia.comtruehttp: //www.bkjia.com/PHPjc/718628.htmlTechArticle1. Execute the copied code as follows: yum install php-mbstring 2. Modify php.ini (This step is very important , some lxadmin versions cannot be modified automatically) Copy the code as follows: echo 'exte...
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn