Home >Backend Development >PHP Tutorial >How to add extensions to php in ubuntu like windows (for example: mb_string)

How to add extensions to php in ubuntu like windows (for example: mb_string)

WBOY
WBOYOriginal
2016-07-06 13:53:37973browse

After configuring the lamp environment, you now need to open many php extensions, such as mb_string, etc. How to open them? ?

Reply content:

After configuring the lamp environment, you now need to open many php extensions, such as mb_string, etc. How to open them? ?

http://blog.haohtml.com/archives/13059

Shouldn’t this kind of thing belong to Baidu? Why ask?

If there is a corresponding php.ini in mb_string.so, just remove it and restart apache. Generally, it should be there. If it is not downloaded, edit and install, then add php.ini to mb_string.so and restart apache

<code>wget http://.......
tar zxvf mb_s....tgz
phpize
./configure --with-php-config=/usr/bin/php-config
make && sudo make install</code>

Try it, I hope it helps you

Search for .so directly in php.ini, remove the semicolon (;) in front of the extension you want to enable, and just restart Apache after changing it.
To check which extensions are loaded by php, you can use php -m.

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