Additional metadata in wxr export format
|Reported by:||tellyworth||Owned by:||anonymous|
The enclosed patch adds some extra metadata to the wxr xml export file to help support future enhancements and fixes for the importer. The changes should be backwards compatible with previous versions of the importer code.
- There's a new <wp:wxr_version> tag in the channel element that contains a version number indicating the wxr format version (currently 1.0). The same number is in the xmlns:wp attribute but I included it here for easier access using the importer's get_tag() method; and also so we can distinguish between this version (which has the new tags listed below) and previous versions. We should bump the version number iff there is a change that might affect backwards compatibility.
- Two new tags <wp:base_site_url> and <wp:base_blog_url> are there to help the importer know whether it is importing from a different site or the same site. In a normal WP install both tags contain the same URL (i.e. siteurl). In MU, base_site_url will show the main url of the MU install, base_blog_url is the individual blog's url.
- <category> tags now include a nicename attribute so it's possible to fix bug #5447. Each category/tag element is duplicated because the old and existing importer code won't parse the new elements.
- A new <wp:attachment_url> element is added when post_type is 'attachment'. Normally it's the same as the guid but that is not necessarily a reliable assumption for the importer to make.
Change History (4)
Note: See TracTickets for help on using tickets.