Не работает SimpleXMLElement в PHP!
в консоли при наборе php -v
PHP 7.4.8 (cli) (built: Jul 13 2020 16:45:28) ( NTS )
Copyright (c) The PHP Group
Zend Engine v3.4.0, Copyright (c) Zend Technologies
with Zend OPcache v7.4.8, Copyright (c), by Zend Technologies
php -m:
php -m
[PHP Modules]
calendar
Core
ctype
curl
date
dom
exif
FFI
fileinfo
filter
ftp
gettext
hash
iconv
json
libxml
openssl
pcntl
pcre
PDO
Phar
posix
readline
Reflection
session
shmop
SimpleXML
sockets
sodium
SPL
standard
sysvmsg
sysvsem
sysvshm
tokenizer
xml
xmlreader
xmlwriter
xsl
Zend OPcache
zlib
[Zend Modules]
Zend OPcache
Я уже и ставил PHP 7.2, устанавливал php-xml, php-simplexml и все бесполезно. Что не так? Она разве не должна быть встроена в PHP?
log:
PHP Fatal error: Uncaught Error: Class 'SimpleXMLElement' not found in /var/www/html/inc/functions.php:828\nStack trace:\n#0 /var/www/html/inc/templates/dashboard/balance.php(38): get_purchase_url('11111', 'rub', '[email protected]')\n#1 /var/www/html/index.php(9): include('/var/www/html/i...')\n#2 {main}\n thrown in /var/www/html/inc/functions.php on line 828, referer: https://video.mediaz.info/?case=dashboard&page=rooms
php:
$myCurl = curl_init();
curl_setopt_array($myCurl, array(
CURLOPT_URL => $url,
CURLOPT_RETURNTRANSFER => true,
CURLOPT_POST => true,
CURLOPT_POSTFIELDS => http_build_query(array($body))
));
$response = curl_exec($myCurl);
curl_close($myCurl);
$robo_response = new SimpleXMLElement($response);