/settings/export
, export and download the resulting zip archive./settings/import
, import the zip.While our importer only takes WXR file, a user could legitimately assume she can import whatever exported directly.
It would be less confusing to show clearer instructions to inform the user to extract and to upload WXR files individually.
Agreed. It would be nice to detect an uploaded zip file and let someone know that they should unzip first and upload the xml file instead.
I saw a different error when I tested this. I'm including it here for reference:
Unexpected error during the upload
Seen at https://wordpress.com/settings/import/foodescapades.wordpress.com using Chrome 52.0.2743.116 on Mac OS X 10.11.6
Wanted to say +1 to fixing this UX issue.
@m mentioned this one again recently — adding more notes here.
UX issue: When you download an export from WP.com, you end up with a ZIP file. But if you try to upload that ZIP file to import somewhere else on WP.com, it errors because the import needs an unzipped .xml file and not the ZIP format.
This issue has been marked as stale and will be closed in seven days. This happened because:
You can keep the issue open by adding a comment. If you do, please provide additional context and explain why you’d like it to remain open. You can also close the issue yourself — if you do, please add a brief explanation.
@Automattic/delta-samus, this should be pretty straightforward. Let's fix it.
What's preventing us from allowing the zip to be uploaded and extracting the XML on the server? It seems like that would be a better experience than asking the user to unzip it themselves.
We could do some checks to ensure that the zip only contains an appropriate import file as a security measure.
@pablinos Actually I had proposed it in https://github.com/Automattic/hg/issues/147#issuecomment-229545699 . The only reason we didn't aim for that was because we simply didn't have the bandwidth. Sarcastically, we still don't have the bandwidth even after we scoped it down 🙃
If we implement zip uploading, I think we should still support WXR uploading and provide clear instructions that both uploading a zipped WXRs archive and a WXR will work.
If we can patch the client to get the zip file to PHP, we can extract only appropriate files by passing them to the 2nd param of ZipArchive::extractTo.
Tagging @Automattic/delta-samus on this one as it came up again yesterday in an empathy challenge posted by @m.
@bisko is working some magic in D16447-code
Ran into this today in #8049949-hc.
The user was attempting to upload the enclosing file folder, rather than the zip or the .xml. This is because when a site is exported, a zip is downloaded and some OS open these automatically.
Then you have the zip archive, the enclosing folder, and the .xml file within.
Uploading the enclosing folder results in this error:
Whatever error we display here should specify the acceptable filetype(s) the importer will accept.
It would also be helpful to specify this below the importer in the first place. "Upload a WordPress export file" doesn't help someone who doesn't know what a WordPress export file means.
Adding specific filetype(s) here would be great.
@thehenrybyrd Seems like an XML file in the Zip archive was having broken encoding. We have a fix in place for testing, but it's not fully released to the public.
You can enable the feature for the customer's site and let them try the import again.
More information here: p7DVsv-5Hb-p2
Hey I know this issue has been stale for a while, but thought I could help out:
ZIP and WXR are both supported now, and the UI copy had been updated a while back to indicate that:
Next, to add specificity to the upload error message, I re-iterate what a valid export file is:
Lastly, when a user contacts support, I propose to make that link more specific and skip the self-serve articles and go straight to /help/contact:
I got feedback on the proposed solution, to not link the message directly to support, but to keep the link as-is, pointing to the Help section. In that case, I changed the original error message for accuracy, since that wasn't contacting support either:
Thanks for tackling this, @dezzie 🙇
Most helpful comment
If we can patch the client to get the zip file to PHP, we can extract only appropriate files by passing them to the 2nd param of ZipArchive::extractTo.