By stu1106
In my WordPress install when I try to run the importer to import an xml file, the .txt extension is being added to the end and the file ends up in the media library. I receive this error ‘The export file could not be found at /var/www/html/wp-content/uploads/2020/07/****.xml_.txt. It is likely that this was caused by a permissions problem.’ I’m stuck with this and haven’t been able to find anything related to the issue.
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Hi @stu1106,
With the plugin are you getting the same issue?
One other thing, can you try and install PHP 7.4 with the following commands:
sudo apt-get update
sudo apt -y install software-properties-common
sudo add-apt-repository ppa:ondrej/php
sudo apt-get update
sudo apt -y install php7.4
sudo apt-get install -y php7.4-{bcmath,bz2,intl,gd,mbstring,mysql,zip}
You’ll need to add a few more extensions to your php7.4 - dom, gmagick, SimpleXML, ssh2, XML, xmlreader, curl, date, exit, filter , ftp, gd, hash, iconv, imagick, json, libxml, mbstring, mysqli, openssl, pcre, posix, sockets, SPL, tokenizer, zlib, pdo.
All of the extensions should be installed like so
apt-get install -y php7.4-iconv
Regards, KFSys
Hi @stu1106,
In most cases you have a PHP extension missing that’s preventing it from working properly. In your case, You’ll need to install the PHP DomDocument extension. This extension is actually contained in XML.
Do you know if you are using Ubuntu or Apache? If it’s Ubuntu, you can use the following command
sudo apt-get install php-xml
If you are using CentOS
yum install php-xml
Regards, KFSys
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.