Ticket #16790 (reviewing enhancement)

Opened 15 months ago

Last modified 15 months ago

Functional spec for wpautop

Reported by: mrclay Owned by:
Priority: normal Milestone: Awaiting Review
Component: Unit Tests Version:
Severity: minor Keywords:
Cc: steve@…

Description

I've put together an algorithm-based  functional spec that I hope could be useful in maintaining wpautop. Also might be handy is this combination of  wpautop failure cases.

The algorithm is based on work I've started on a DOMDocument-based implementation (a project I contribute to needs an MIT-licensed version), and although it's incomplete and slow, it does a bang-up job so far.

DOMDocument may just be too slow or strict in its parsing to allow the variety of markup that wpautop needs to accept, but it's ace at the level of surgical precision needed to do this right.

Change History

  • Owner set to scribu
  • Status changed from new to reviewing

Although not directly relevant, it's good to remember that the HTML runs through kses afterwards, which can alter it significantly.

  • Owner scribu deleted
Note: See TracTickets for help on using tickets.