未定义的函数http_post_data()

时间:2018-06-22 17:31:48

标签: php ubuntu ubuntu-18.04 php-7.0

我正在使用PHP 7.0.30-1 + ubuntu18.04.1 + deb.sury.org + 1。以下是我加载的扩展程序

Array ( [0] => Core [1] => date [2] => libxml [3] => openssl [4] =>
pcre [5] => zlib [6] => filter [7] => hash [8] => Reflection [9] =>
SPL [10] => session [11] => standard [12] => apache2handler [13] =>
propro [14] => raphf [15] => PDO [16] => xml [17] => calendar [18] =>
ctype [19] => curl [20] => dom [21] => exif [22] => fileinfo [23] =>
ftp [24] => gettext [25] => iconv [26] => json [27] => mcrypt [28] =>
Phar [29] => posix [30] => readline [31] => shmop [32] => SimpleXML
[33] => sockets [34] => sysvmsg [35] => sysvsem [36] => sysvshm [37]
=> tokenizer [38] => wddx [39] => xmlreader [40] => xmlwriter [41] =>
xsl [42] => http [43] => Zend OPcache )

但是我总是遇到错误

致命错误:未捕获的错误:调用未定义的函数http_post_data()

当我尝试安装pecl_http时,出现以下错误 enter image description here

请帮助我。

1 个答案:

答案 0 :(得分:0)

您需要按以下顺序将这些扩展名添加到您的php.ini文件中

extension=raphf.so
extension=propro.so
extension=http.so

要解决“ zlib”问题read the solution to this post