Opened 16 years ago
Closed 16 years ago
#7624 closed defect (bug) (fixed)
Export blog feature produces invalid XML file
Reported by: | rjwalsh | Owned by: | |
---|---|---|---|
Milestone: | 2.7 | Priority: | high |
Severity: | major | Version: | 2.6.1 |
Component: | Export | Keywords: | has-patch commit dev-feedback |
Focuses: | Cc: |
Description
The WXR output is not valid XML. Using minidom in Python (which uses Expat) to read the file can produce an error like this:
xml.parsers.expat.ExpatError: unbound prefix: line 90, column 0
Looking at the line in question, we see something like this:
<excerpt:encoded><![CDATA[]]></excerpt:encoded>
The excerpt namespace is not defined. We need to add something like this to the rss attributes near the top of the file:
xmlns:excerpt="http://wordpress.org/excerpt"
or some similar URL.
Attachments (1)
Change History (9)
#1
@
16 years ago
- Priority changed from normal to high
- Severity changed from normal to major
- Version changed from 2.5.1 to 2.6.1
#2
@
16 years ago
I have successfully reproduced this bug on 2.6.2 and WordPress.com on the date the note was made. Attached is a patch to fix this issue.
#4
@
16 years ago
- Keywords has-patch dev-feedback added
As well as defining the namespace, A file needs to exist at the URL which describes the except namespace. Not something most people understand how to create..
I can confirm that this also triggers errors in Firefox 3 and xml star, and prevents successful importation into Movable Type. I exported from WP 2.6 and 2.6.1.