[LAMP] Fatalerror: Calltoundefinedfunctionmb_detect_encoding (). how can this problem be solved?

Source: Internet
Author: User
Tags ereg spl zts
[LAMP] Fatalerror: Calltoundefinedfunctionmb_detect_encoding () This post is last written by default7 in the Directory & nbsp; homedef [LAMP] Fatal error: call to undefined function mb_detect_encoding ()

This post was last edited by default7 at 14:52:48

I installed lampenvironment, php-xxx-.tar.gz decompressed directory/home/default7/LAMP/php-5.5.13
PHP installation directory/usr/local/php5
After installation, open phpmyadmin and report the following error:


Fatal error: Call to undefined function mb_detect_encoding() in /usr/local/apache2/htdocs/phpmyadmin/libraries/php-gettext/gettext.inc on line 177


Run the command to view the installed php modules: Mbstring exists..
Reference
[[Email protected] php-5.5.13] # php-m
[PHP Modules]
Bz2
Calendar
Core
Ctype
Curl
Date
Ereg
Exif
Fileinfo
Filter
Ftp
Gettext
Gmp
Hash
Iconv
Json
Libxml
Mbstring
Openssl
Pcntl
Pcre
Phar
Readline
Reflection
Session
Shmop
SimpleXML
Sockets
SPL
Standard
Tokenizer
Xml
Zip
Zlib

[Zend Modules]


Check the phpinfo file. The following table lists the related information:

PHP Version 5.5.13
Configure Command
'./configure' '--with-apxs2=/usr/local/apache2/bin/apxs' '--with-mysql' '--prefix=/usr/local/php5'

Server API
Apache 2.0 Handler

Virtual Directory Support
enabled

Configuration File (php.ini) Path
/usr/local/php5/lib

Loaded Configuration File
/usr/local/php5/lib/php.ini

Scan this dir for additional .ini files (none)
Additional .ini files parsed (none)
extension_dir
/usr/local/php5/lib/php/extensions/no-debug-zts-20121212
/usr/local/php5/lib/php/extensions/no-debug-zts-20121212



View the extension directory (empty) after php5 installation ):

[[email protected] ext]# ll /usr/local/php5/lib/php/extensions/no-debug-zts-20121212
total 488
-rwxr-xr-x. 1 root root 495775 Jun 15 01:01 opcache.so
[[email protected] ext]# ll /usr/local/php5/lib/php/extensions
total 4
drwxr-xr-x. 2 root root 4096 Jun 15 01:01 no-debug-zts-20121212


However, there is another directory in the installed Directory (directory/usr/local/php5/include/php/ext ):

[[email protected] ext]# pwd
/usr/local/php5/include/php/ext
[[email protected] ext]# ll
total 68
drwxr-xr-x. 3 root root 4096 Jun 15 01:01 date
drwxr-xr-x. 2 root root 4096 Jun 15 01:01 dom
drwxr-xr-x. 3 root root 4096 Jun 15 01:01 ereg
drwxr-xr-x. 2 root root 4096 Jun 15 01:01 filter
drwxr-xr-x. 2 root root 4096 Jun 15 01:01 hash
drwxr-xr-x. 2 root root 4096 Jun 15 01:01 iconv
drwxr-xr-x. 2 root root 4096 Jun 15 01:01 json
drwxr-xr-x. 2 root root 4096 Jun 15 01:01 libxml
drwxr-xr-x. 2 root root 4096 Jun 15 01:02 mysqlnd
drwxr-xr-x. 3 root root 4096 Jun 15 01:01 pcre
drwxr-xr-x. 2 root root 4096 Jun 15 01:02 pdo
drwxr-xr-x. 2 root root 4096 Jun 15 01:01 phar
drwxr-xr-x. 2 root root 4096 Jun 15 01:01 session
drwxr-xr-x. 2 root root 4096 Jun 15 01:01 spl
drwxr-xr-x. 3 root root 4096 Jun 15 01:01 sqlite3
drwxr-xr-x. 2 root root 4096 Jun 15 01:02 standard
drwxr-xr-x. 2 root root 4096 Jun 15 01:02 xml
[[email protected] ext]#




There is mbstring in the installation folder (/home/default7/LAMP/php-5.5.13/ext:

[[email protected] ext]# ll
total 328
drwxr-xr-x. 4 1001 1001 4096 May 28 17:06 bcmath
drwxr-xr-x. 3 1001 1001 4096 May 28 17:06 bz2
drwxr-xr-x. 3 1001 1001 4096 May 28 17:06 calendar
drwxr-xr-x. 3 1001 1001 4096 May 28 17:06 com_dotnet
drwxr-xr-x. 4 1001 1001 4096 Jun 15 00:27 ctype
drwxr-xr-x. 3 1001 1001 4096 May 28 17:06 curl
drwxr-xr-x. 5 1001 1001 4096 Jun 15 00:25 date
drwxr-xr-x. 6 1001 1001 4096 May 28 17:06 dba
drwxr-xr-x. 5 1001 1001 4096 Jun 15 00:27 dom
drwxr-xr-x. 4 1001 1001 4096 May 28 17:06 enchant
drwxr-xr-x. 5 1001 1001 4096 Jun 15 00:25 ereg
drwxr-xr-x. 3 1001 1001 4096 May 28 17:06 exif
-rwxr-xr-x. 1 1001 1001 8174 May 28 17:06 ext_skel

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.