Я получаю фатальную ошибку PHP:
Call to undefined function curl_init() error while testing some PHP code on my server.
Я предположил, что нужно установить Curl, поэтому сначала нашел версию PHP:
php --version
PHP 5.6.11-1ubuntu3.4 (cli)
Я приступил к установке пакета:
sudo apt-get install php5-curl
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package php5-curl
Я тогда попробовал:
sudo apt install php-curl
и он, кажется, устанавливается, но я видел ссылки на PHP 7, и он успешно завершен.
Тем не менее, проблема сохраняется.
Как запустить curl, чтобы остановить ошибку init ()?
ОБНОВЛЕНИЕ: Когда я запускаю это, я получаю:
sudo apt-get install curl
Reading package lists... Done
Building dependency tree
Reading state information... Done
curl is already the newest version (7.47.0-1ubuntu2.13).
0 upgraded, 0 newly installed, 0 to remove and 172 not upgraded.