Moodle requires the iconv PHP extension. Please install or enable the iconv extension.

Web、Mail、Ftp、DNS、Proxy、VPN、Samba、LDAP 等基础网络服务
回复
头像
zjnx
帖子: 66
注册时间: 2006-04-03 11:27
联系:

Moodle requires the iconv PHP extension. Please install or enable the iconv extension.

#1

帖子 zjnx » 2019-02-16 21:04

Moodle requires the iconv PHP extension. Please install or enable the iconv extension.

Moodle的安装版本为moodle-latest-36.tgz

ubuntu版本为
moodle@moodle:/$ cat /proc/version
Linux version 4.18.0-15-generic (buildd@lgw01-amd64-007) (gcc version 8.2.0 (Ubuntu 8.2.0-7ubuntu1)) #16-UbuntuSMP Thu Feb 7 10:56:39 UTC 2019

php的版本为
moodle@moodle:/$ php -v
PHP 7.2.15-0ubuntu0.18.10.1 (cli) (built: Feb 8 2019 14:54:22) ( NTS )
Copyright (c) 1997-2018 The PHP Group
Zend Engine v3.2.0, Copyright (c) 1998-2018 Zend Technologies
with Zend OPcache v7.2.15-0ubuntu0.18.10.1, Copyright (c) 1999-2018, by Zend Technologies

我在php.ini里面看了确实没有iconv这个扩展插件
没有办法,只好进行apt安装
安装的时候却提示
moodle@moodle:/$ sudo apt-get install php7.2-iconv
Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'php7.2-common' instead of 'php7.2-iconv'
php7.2-common is already the newest version (7.2.15-0ubuntu0.18.10.1).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
moodle@moodle:/$ sudo apt-get install php7.2-common
Reading package lists... Done
Building dependency tree
Reading state information... Done
php7.2-common is already the newest version (7.2.15-0ubuntu0.18.10.1).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
moodle@moodle:/$

请问我该如何安装iconv这个扩展插件并启用他

感谢各位大神:)
头像
astolia
论坛版主
帖子: 6460
注册时间: 2008-09-18 13:11

Re: Moodle requires the iconv PHP extension. Please install or enable the iconv extension.

#2

帖子 astolia » 2019-02-17 15:46

不懂php,但iconv已经包含在php7.2-common里了。
插件文件在/usr/lib/php/20170718/iconv.so
配置在/usr/share/php7.2-common/common/iconv.ini
头像
zjnx
帖子: 66
注册时间: 2006-04-03 11:27
联系:

Re: Moodle requires the iconv PHP extension. Please install or enable the iconv extension.

#3

帖子 zjnx » 2019-02-17 16:54

恩谢谢楼主的回答,但我不知道为嘛还老提示我要启动这个控件。。。
我即使在php.ini中加了
extension=iconv
或者
extension=php_iconv
这个重新启动apache2服务后还是如此
回复