Question: I'm testing PHP7, and have a weird issue after a recent update. SimpleXML should be enabled by default, and my `phpinfo` page shows that it is available:

[![enter image description here](https://i.stack.imgur.com/F5qwX.png)](https://i.stack.imgur.com/F5qwX.png)

However, the functions are not available:

```
<?php

if (function_exists('simplexml_load_file')) {
    echo "simpleXML functions are available.<br />\n";
} else {
    echo "simpleXML functions are not available.<br />\n";
}

// result-- NOT available

```

And the module isn't listed as loaded:

```
~ $ php -m
[PHP Modules]
calendar
Core
ctype
curl
...
Reflection
session
shmop
sockets
SPL
standard
sysvmsg
sysvsem
sysvshm
tokenizer
Zend OPcache
zlib

```

Anyone know if there's a workaround for this?

Version info:

```
~ $ php -v
PHP 7.0.3-8+deb.sury.org~trusty+2 (cli) ( NTS )
Copyright (c) 1997-2016 The PHP Group
Zend Engine v3.0.0, Copyright (c) 1998-2016 Zend Technologies
    with Zend OPcache v7.0.6-dev, Copyright (c) 1999-2016, by Zend Technologies

```

Answer: 
For Ubuntu 18.04 and php7.3, install php7.3-xml

```
    sudo apt-get install php7.3-xml

```

this will installl the required simplexml
in my case, you have to make sure about your php version.

```
php -v

```

example: if your php is PHP 7.4.28, than you have to write

```
sudo apt install php7.4-xml

```

see, instead to write all version, just write the first and second, than following with `-xml`

I have this issue and it's take time, until I understand how to write properly. hopefully it's work for you