Make WordPress Core

Opened 18 years ago

Closed 16 years ago

Last modified 16 years ago

#8471 closed enhancement (fixed)

make export/import output valid xml and parse xml using simplexml

Reported by: tott Owned by: westi
Priority: lowest Milestone: 3.1
Component: Export Version: 2.7
Severity: trivial Keywords: needs-patch
Cc: Focuses:

Description

WXR Export as well as export.php script is not properly indented.

Attached is a small fix that produces well indented xml and improves readability in export.php script.

Attachments (2)

export-indent.diff​ (22.1 KB ) - added by tott 18 years ago.
patch against rev 10020 indenting wxr exports as well as improving readbility in export.php
8471.r10258.diff​ (15.6 KB ) - added by jacobsantos 18 years ago.
Based off of r10258

Download all attachments as: .zip

Change History (14)

@tott
18 years ago

patch against rev 10020 indenting wxr exports as well as improving readbility in export.php

#1 @lloydbudd
18 years ago

  • Owner changed from tott to westi

#2 @lloydbudd
18 years ago

  • Keywords has-patch added

#3 @jacobsantos
18 years ago

  • Keywords export, indenting, formatting, wxr, has-patch → export indenting formatting wxr has-patch

#4 @jacobsantos
18 years ago

The phpdoc should not be indented. It is good as it is.

#5 @jacobsantos
18 years ago

  • Separates functions out of the export_wp() function.
  • indents the lines inside export_wp().


The problem is that since the import uses regular expressions, you can't really change the indentation without correcting the importer as well. When the importer switches over to using XML, then it can be done.

#6 @Denis-de-Bernardy
18 years ago

  • Keywords needs-patch added; export indenting formatting wxr has-patch removed
  • Milestone 2.8 → Future Release
  • Severity normal → trivial
  • Summary WXR Export formatting → make export/import output valid xml and parse xml using simplexml
  • Version → 2.7

#7 @hakre
18 years ago

-1 for SimpleXML, +1 for DOM-XML. Just to save us some headaches then.

#8 @hakre
18 years ago

see also #9633.

#9 @link92
17 years ago

Equally see #7400.

#10 @hakre
17 years ago

Maybe even drop DOM-XML because SimplePie uses XML Parser Functions: ​http://us2.php.net/manual/en/ref.xml.php

Those are PHP4 as well.

#11 @nacin
16 years ago

  • Resolution → fixed
  • Status new → closed

(In [15961]) Importer and exporter overhaul, mega props duck.

Exporter overhaul:

  • Add author information to export
  • Greater usage of slug identifiers
  • Don't export auto-drafts, spam comments, or edit lock/last meta keys
  • Inline documentation improvements
  • Remove filtering for now (@todo)
  • Bump WXR version to 1.1, but remain back compat in the importer

Importer overhaul (​http://plugins.trac.wordpress.org/changeset/304249):

  • Use an XML parser where available (SimpleXML, XML Parser)
  • Proper import support for navigation menus
  • Many bug fixes, specifically improvements to category and custom taxonomy handling
  • Better author/user mapping

Fixes #5447 #5460 #7400 #7973 #8471 #9237 #10319 #11118 #11144 #11354 #11574 #12685 #13364 #13394 #13453 #13454 #13627 #14306 #14442 #14524 #14750 #15055 #15091 #15108.

See #15197.

#12 @nacin
16 years ago

  • Milestone Future Release → 3.1
Note: See TracTickets for help on using tickets.