Opened 17 years ago
Closed 16 years ago
#12871 closed enhancement (fixed)
Comment meta lost on Export/Import
| Reported by: | Otto42 | Owned by: | duck_ |
|---|---|---|---|
| Priority: | normal | Milestone: | 3.2 |
| Component: | Export | Version: | 3.0 |
| Severity: | normal | Keywords: | 2nd-opinion has-patch |
| Cc: | Focuses: |
Description
When doing a blog export and import, comment meta information is not preserved.
Observed in 2.9.2 and 3.0 B1.
Attachments (5)
Change History (14)
#4
@
16 years ago
- Cc added
- Keywords 2nd-opinion has-patch added; needs-patch removed
As of now, the patch works with SimpleXML, XML and regex(all three!).
#5
@
16 years ago
- Cc added
kapeels patch worked fine for me, thanks! WordPress 3.1.1 with WordPress Importer 0.4.
I've imported 250 comments with two custom fields each, and it all went fine.
I did not tested the export, since I'm generating the XML from a script.
I had to apply the patch "by hand", as the plugin code changed since than. I've just attached the updated version for the importer patch, ready to be applied in plugin version 0.4. I did not change any code from kappels patch, just formatting and line location.
#6
follow-up:
↓ 7
@
16 years ago
- Milestone Future Release → 3.2
Attached slightly reworked patches. Mainly to allow re-use of <wp:meta_(key|value)> tags instead of introducing new, redundant tags for the same purpose. If it weren't for back compat I would go with <wp:meta> for both postmeta and commentmeta too.
Removed some if statements after queries for export since get_results() will always return an array which is fine for the foreach.
Also removed the filter and action for insertion in the importer. Can be reintroduced if there is a use, but don't see a point in just adding them because postmeta has them. The filter to allow disabling certain keys might make more sense, but the action is unnecessary (see added_{$meta_type}_meta).
#7
in reply to: ↑ 6
@
16 years ago
Replying to duck_:
Also removed the filter and action for insertion in the importer. Can be reintroduced if there is a use, but don't see a point in just adding them because postmeta has them. The filter to allow disabling certain keys might make more sense, but the action is unnecessary (see
added_{$meta_type}_meta).
Also filter on key seems unnecessary, see add_{$meta_type}_metadata in add_metadata().
Where is the has-patch?
This ticket has been sitting.
Sad Christmas. Now, punt.