PHPmyadmin问题 - 致命错误:未捕获错误:调用未定义函数mb_detect_encoding()

时间:2016-11-10 19:54:22

标签: phpmyadmin

当我尝试从本地主机运行Phpmyadmin时,我不断遇到此问题。

Fatal error: Uncaught Error: Call to undefined function mb_detect_encoding() 
in C:\Apache24\htdocs\phpmyadmin\libraries\php-gettext\gettext.inc:177 Stack 
trace: #0 C:\Apache24\htdocs\phpmyadmin\libraries\php-
gettext\gettext.inc(282): _en code('The %s extensio...') #1 
C:\Apache24\htdocs\phpmyadmin\libraries\php-gettext\gettext.inc(289): _
gettext('The %s extensio...') #2 
C:\Apache24\htdocs\phpmyadmin\libraries\core.lib.php(306): __('The %s 
extensio...') #3 C:\Apache24\htdocs\phpmyadmin\libraries\core.lib.php(961): 
PMA_warnMissingExtension('mbstring', true) #4 
C:\Apache24\htdocs\phpmyadmin\libraries\common.inc.php(102): 
PMA_checkExtensions() #5 C:\Apache24\htdocs\phpmyadmin\index.php(13): 
require_once('C:\\Apache24\\htd...') #6 {main} thrown in 
C:\Apache24\htdocs\phpmyadmin\libraries\php-gettext\gettext.inc on line 177

我已多次通过并尝试了有关此问题的所有建议,但尚未弄清楚。我尝试了各种各样的" /" " \"建议没有运气。

以下是我的httpd.conf设置:

ServerRoot "c:/Apache24"


 </IfModule>
 LoadModule php7_module "c:/php/php7apache2_4.dll"
 AddHandler application/x-httpd-php .php
 PHPIniDir "c:\PHP"

以下是我的php.ini设置:

 ; Directory in which the loadable extensions (modules) reside.
 ; http://php.net/extension-dir
   extension_dir = "C:/PHP/ext"
 ; On windows:
   extension_dir = "C:/PHP/ext"   



 ;extension=php_bz2.dll
 ;extension=php_curl.dll
 ;extension=php_fileinfo.dll
 ;extension=php_ftp.dll
  extension=php_gd2.dll
  extension=php_gettext.dll
 ;extension=php_gmp.dll
 ;extension=php_intl.dll
 ;extension=php_imap.dll
 ;extension=php_interbase.dll
 ;extension=php_ldap.dll
  extension=php_mbstring.dll
  extension=php_exif.dll      ; Must be after mbstring as it depends on it
  extension=php_mysqli.dll
 ;extension=php_oci8_12c.dll  ; Use with Oracle Database 12c Instant Client
 ;extension=php_openssl.dll
 ;extension=php_pdo_firebird.dll
 ;extension=php_pdo_mysql.dll
 ;extension=php_pdo_oci.dll
 ;extension=php_pdo_odbc.dll
 ;extension=php_pdo_pgsql.dll
 ;extension=php_pdo_sqlite.dll
 ;extension=php_pgsql.dll
 ;extension=php_shmop.dll

PHPINFO

 PHP Version 7.0.13
 System Windows NT SERVER 6.3 build 9600 (Windows Server 2012 R2    
 Standard Edition) AMD64
 Build Date Nov 8 2016 13:28:54
 Compiler   MSVC14 (Visual C++ 2015)
 Architecture   x64
 Configure Command  cscript /nologo configure.js "--enable-snapshot-build"      
 "--enable-debug-pack" "--with-pdo-oci=c:\php-  
 sdk\oracle\x64\instantclient_12_1\sdk,shared" "--with-oci8-12c=c:\php-
 sdk\oracle\x64\instantclient_12_1\sdk,shared" "--enable-object-out-
 dir=../obj/" "--enable-com-dotnet=shared" "--with-mcrypt=static" "-- 
 without-analyzer" "--with-pgo"
 Server API Apache 2.0 Handler
 Virtual Directory Support  enabled
 Configuration File (php.ini) Path  C:\Windows
 Loaded Configuration File  (none)
 Scan this dir for additional .ini files    (none)
 Additional .ini files parsed   (none)
 PHP API    20151012
 PHP Extension  20151012
 Zend Extension 320151012
 Zend Extension Build   API320151012,TS,VC14
 PHP Extension Build    API20151012,TS,VC14
 Debug Build    no
 Thread Safety  enabled
 Zend Signal Handling   disabled
 Zend Memory Manager    enabled
 Zend Multibyte Support disabled
 IPv6 Support   enabled
 DTrace Support disabled
 Registered PHP Streams php, file, glob, data, http, ftp, zip,      
 compress.zlib, phar
 Registered Stream Socket Transports    tcp, udp
 Registered Stream Filters  convert.iconv.*, mcrypt.*, mdecrypt.*,   
 string.rot13, string.toupper, string.tolower, string.strip_tags, convert.*,  
 consumed, dechunk, zlib.*

软件/硬件

 - Windows Server 2016R2
 - PHP 7.0.13
 - Phpmyadmin (C:\Apache24\htdocs\phpmyadmin)
 - Apache 2.4
 - MySQL 5.7.1

我感谢你能给我的任何帮助。不知道要采取什么措施。

2 个答案:

答案 0 :(得分:0)

我在Windows 10上遇到了同样的问题,Bitnami WAMP Stack版本7.0.12-0(不确定你是使用Bitnami还是其他一些WAMP堆栈,或者没有)。我放弃了故障排除(你试过运行命令:

cd \php
deplister ext\php_mbstring.dll

在命令提示符中,检查PHP_MBSTRING.DLL的依赖关系,看看是否有任何&#34; NOTFOUND&#34;错误?),刚安装了最新版本的Bitnami,7.0.13-1,然后phpMyAdmin立即工作。 (我在之前版本的Bitnami中稍微更改了我的httpd.conf和php.ini,所以我可能已经破坏了phpMyAdmin这些更改。)

答案 1 :(得分:0)

我有同样的问题 我只是在php.ini文件中更新完整的扩展文件夹路径

extension_dir = "C:/wamp/bin/php/php7.1.13/ext/"

并更新了最新的phpmyadmin版本 因为phpmyadmin4.1.14与php7不兼容。 我希望它能解决你的问题