Home >Backend Development >PHP7 >How to install mbstring extension in php7

How to install mbstring extension in php7

藏色散人
藏色散人Original
2021-06-18 10:47:153711browse

How to install the mbstring extension in php7: first enter the source package "ext/mbstring" directory; then run phpize and install the basic package; then modify the configuration information; and finally restart the php-fpm service.

How to install mbstring extension in php7

The operating environment of this article: Windows7 system, PHP7.1 version, DELL G3 computer

How to install the mbstring extension in php7?

PHP7.4 Install Mbstring extension

Installation steps

Enter the ext/mbstring directory under the source code package

cd /home/work/study/softpackage/php-7.4.4/ext/mbstring

Run phpize

/home/work/study/soft/php/bin/phpize

Install the basic package

yum install -y oniguruma oniguruma-devel

Run

./configure --with-php-config=/usr/local/php/bin/php-config
make && make install

Modify the configuration information

vim /home/work/study/soft/php/lib/php.ini

Modify php.ini and add

extension_dir="/home/work/study/soft/php/lib/php/extensions/no-debug-non-zts-20190902/"
extension=mbstring.so
to the configuration file

Restart the php-fpm service

pkill -9 php-fpm
php-fpm

may report an error

No package 'oniguruma' found
yum install -y oniguruma oniguruma-devel

Recommended study: "PHP Video Tutorial"

The above is the detailed content of How to install mbstring extension in php7. For more information, please follow other related articles on the PHP Chinese website!

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