Call to undefined function simplexml load string

Call to undefined function simplexml load string

При попытке забрать xml через консоль выдает ошибку

Притом самое интересное, что через браузер библиотека работает и все ок.

В списке библиотек ее нету php -m

При попытке поставить 404 ошибка (куча 404, т.е. репы не доступны)
Как только не пhобывал
apt-get install php7.2-xml
apt-get install php7.2-simplexml

Если, что доступ к удаленным url разрешен allow_url_fopen = On

I am implementing facebook count function using cron file. In which cron runs every 10 minutes and counts the total likes of a page.

But I am geting undefined call function error.

5 Answers 5

For PHP 7 and Ubuntu 14.04 the procedure is follows. Since PHP 7 is not in the official Ubuntu PPAs you likely installed it through Ondřej Surý’s PPA (sudo add-apt-repository ppa:ondrej/php). Go to /etc/php/7.0/fpm and edit php.ini, uncomment to following line:

Then simply install php7.0-xml:

And restart PHP:

And restart Apache:

If you are on a later Ubuntu version where PHP 7 is included, the procedure is most likely the same as well (except adding any 3rd party repository).

I am implementing facebook count function using cron file. In which cron runs every 10 minutes and counts the total likes of a page.

But I am geting undefined call function error.

5 Answers 5

For PHP 7 and Ubuntu 14.04 the procedure is follows. Since PHP 7 is not in the official Ubuntu PPAs you likely installed it through Ondřej Surý’s PPA (sudo add-apt-repository ppa:ondrej/php). Go to /etc/php/7.0/fpm and edit php.ini, uncomment to following line:

Then simply install php7.0-xml:

And restart PHP:

And restart Apache:

If you are on a later Ubuntu version where PHP 7 is included, the procedure is most likely the same as well (except adding any 3rd party repository).

Ссылка на основную публикацию
Adblock detector