- This topic has 13 replies, 1 voice, and was last updated 2 years, 6 months ago by
Paul.
-
AuthorPosts
-
June 15, 2019 at 2:36 am #930304
Khanh Nguyen
Hi,
I tried to import a site from Site Library. The interface has a changes, and look like the same with the site imported, but it has no demo content (demo posts).
Although I followed the steps in this link:
https://docs.generatepress.com/article/using-the-site-library/June 15, 2019 at 8:29 am #930628David
StaffCustomer SupportHi there,
when importing a site, the second step has a notification and a check box that needs to be checked in order for you to click the import button. Did you follow this step? Let me know.
June 15, 2019 at 3:33 pm #930883Khanh Nguyen
Yes, I checked “I understand…” check box and clicked Import Content button, but It’s has no demo content.
I have checked error log and found it:
*177 FastCGI sent in stderr: "PHP message: PHP Warning: XMLReader::read(): /var/www/html/xxxxxxxxxxxxxx.com/public_html/wp-content/uploads/2019/06/content-1.xml:1: parser error : Document is empty in /var/www/html/xxxxxxxxxxxxxx.com/public_html/wp-content/plugins/gp-premium/sites/libs/wxr-importer/WXRImporter.php on line 344
A part of content of /var/www/html/xxxxxxxxxxxxxx.com/public_html/wp-content/uploads/2019/06/content-1.xml:
^_<8b>^H^@^@^@^@^@^@^Cí}ýrãF<92>çߣ<88>y<87>^ZvìîÌ<9e>@^Qà§Ø<92>ìvO^?íºí^N·ú¼^[^N^G£^H^TI¸A^T<8c>^BDÑ<8e><8e><98>w¸ûç^^ã^á^^e<9e>ä2«ðE<90>^T <8a>^T!^Y=<9e>n ¨<8f>¬Ì¬Ì_f%<80><8b>¯n§^N¹a¾°¹{YÓë<8d>^Za®É-Û^]_Ö>]¿Öz5òÕÕÉÅ_4<8d>\OlAà?J~ä¾õÁgB^Pö_^As-f<91>^_>~$#ÛadÌ\æÓ^@.^Mç<99><86>^Tþs »õ¸^_^P>"s^^úDØ^A«^SM<8b>&x^W^P<93>»^Aµ]<98>Ç^]
June 15, 2019 at 5:42 pm #930925Tom
Lead DeveloperLead DeveloperHmm, that doesn’t look right. Which site are you importing?
Can you try the import again after deleting any existing .xml files? I wonder if something on your server is changing/sanitizing the content.xml files before they’re downloaded.
June 15, 2019 at 6:53 pm #930941Khanh Nguyen
I tried delete existing .xml files but It still happen.
It happen to any site in Site Library.
I use the VPS and my website is fresh (no content). So I can give you access (both of VPS and WordPress Dashboard) if you want to check something.June 16, 2019 at 3:48 am #931157Khanh Nguyen
I’m facing this issue with both of Linode (nginx) and Azure VM (nginx), but Shared Hosting (Hawkhost with apache) is ok.
Please take attention. I have to pass this issue asap.
June 16, 2019 at 5:21 am #931200Khanh Nguyen
Hi there,
Any solution for me?Thank you so much.
June 16, 2019 at 8:29 am #931440Tom
Lead DeveloperLead DeveloperI’ve been looking into this and can’t find why the xml file is becoming corrupt during the download to your VPS.
If you check the xml file on your shared hosting, does it look the same as on your VPS?
If needed, we can just manually import the xml file.
June 16, 2019 at 9:34 am #931509Khanh Nguyen
Hi Tom,
I also have a Shared Hosting and this function work well on Shared Hosting (the xml file looks very clear)
<?xml version="1.0" encoding="UTF-8" ?> <!-- This is a WordPress eXtended RSS file generated by WordPress as an export of your site. --> <!-- It contains information about your site's posts, pages, comments, categories, and other content. --> <!-- You may use this file to transfer that content from one site to another. --> <!-- This file is not intended to serve as a complete backup of your site. --> .....more .....
So I think there are something wrong with my web-server configuration or php configuration (on linode vps and azure vm).
But with Shared Hosting, only wordpress source code is under my control. I can not investigate web-server configuration or php configuration in shared hosting so I can not know the difference.
The only difference I know is: Shared Hosting is running Apache – Linode VPS and Azure VM are running Nginx.
It would be good if you can take a look on my VPS (I can give you permission, it just a test site so you can).
June 16, 2019 at 3:44 pm #931687Tom
Lead DeveloperLead DeveloperUnfortunately, I don’t know enough about specific server configurations to know what’s going on here.
Perhaps the server security/firewall is “sanitizing” the xml file? Is there anything there you can test (temporarily disabling firewall for a minute etc..)?
June 16, 2019 at 8:31 pm #931761Khanh Nguyen
Firewall was disable but the issue still appears.
I tried debug with WordPress log and this is something that I got:[17-Jun-2019 04:25:51 UTC] PHP Notice: Undefined index: masonry_width in /var/www/html/xxxxx.com/public_html/wp-content/plugins/gp-premium/sites/classes/class-site-helper.php on line 146 [17-Jun-2019 04:25:51 UTC] PHP Notice: Undefined index: masonry_most_recent_width in /var/www/html/xxxxx.com/public_html/wp-content/plugins/gp-premium/sites/classes/class-site-helper.php on line 146 [17-Jun-2019 04:27:29 UTC] PHP Warning: XMLReader::read(): /var/www/html/xxxxx.com/public_html/wp-content/uploads/2019/06/content-11.xml:1: parser error : Document is empty in /var/www/html/xxxxx.com/public_html/wp-content/plugins/gp-premium/sites/libs/wxr-importer/WXRImporter.php on line 344 [17-Jun-2019 04:27:29 UTC] PHP Warning: XMLReader::read(): ^_�^H in /var/www/html/xxxxx.com/public_html/wp-content/plugins/gp-premium/sites/libs/wxr-importer/WXRImporter.php on line 344 [17-Jun-2019 04:27:29 UTC] PHP Warning: XMLReader::read(): ^ in /var/www/html/xxxxx.com/public_html/wp-content/plugins/gp-premium/sites/libs/wxr-importer/WXRImporter.php on line 344 [17-Jun-2019 04:27:31 UTC] == Start mapping menu locations == [17-Jun-2019 04:27:31 UTC] PHP Notice: Undefined offset: 2 in /var/www/html/xxxxx.com/public_html/wp-content/plugins/gp-premium/sites/classes/class-site-helper.php on line 401 [17-Jun-2019 04:27:31 UTC] PHP Notice: Undefined offset: 2 in /var/www/html/xxxxx.com/public_html/wp-content/plugins/gp-premium/sites/classes/class-site-helper.php on line 402 [17-Jun-2019 04:27:31 UTC] 2 ->
How can I debug the content xml download processing ?
June 17, 2019 at 2:53 am #932022Khanh Nguyen
Hi Tom,
Good news 🙂
I found the root cause: I miss some php extensions.
I don’t know exactly which extension but these are all extensions that I installed to fixing this issue:
sudo apt -y install php-curl php-gd php-intl php-mbstring php-soap php-xml php-xmlrpc php-zip
Hope it will be useful for the one who facing this issue.
June 17, 2019 at 8:03 am #932397Tom
Lead DeveloperLead DeveloperAwesome! Glad you got it working. Thanks for sharing what you did 🙂
November 20, 2020 at 1:56 pm #1539460Paul
khanh you’re the man! 🙂
i had a new site on php 7.4 and didn’t have all the modules setup for that version of php.
doing it now but sure that’s the issue. THANKS. -
AuthorPosts
- You must be logged in to reply to this topic.