【问题标题】:Why mbstring extension is missing?为什么缺少 mbstring 扩展名?
【发布时间】:2019-07-10 09:02:42
【问题描述】:

我正在尝试增加 PHP 脚本的最大执行时间

ini_set('max_execution_time', 90000);

在“php.ini”文件中,但在我重新启动服务器后,我在 PHPMyAdmin 中出现错误“mbstring extension is missing”。如果我用“ini_set”注释行,PHPMyAdmin 工作正常。

那么,为什么 mbstring 扩展停止工作?

【问题讨论】:

  • 可以用命令行工具安装mbstring吗?像 sudo apt-get install php7.0-mbstring

标签: php phpmyadmin


【解决方案1】:

php.ini 是一个配置文件,而不是一个脚本,所以你不能从中运行代码。当您尝试用 PHP 源代码填充它时,您会破坏文件,因此 PHP 会以其编译的默认值开始,其中不包括 mbstring。

;;;;;;;;;;;;;;;;;;;
; Resource Limits ;
;;;;;;;;;;;;;;;;;;;

; Maximum execution time of each script, in seconds
; http://php.net/max-execution-time
; Note: This directive is hardcoded to 0 for the CLI SAPI
max_execution_time = 30

【讨论】:

    猜你喜欢
    • 2018-02-20
    • 2016-03-01
    • 2018-12-11
    • 2016-05-12
    • 2018-08-11
    • 2016-06-19
    • 2016-10-11
    • 1970-01-01
    相关资源
    最近更新 更多