Anne van Kesteren wrote:
On Wed, 29 Nov 2006 17:10:10 +0100, Robert Sayre <[EMAIL PROTECTED]> wrote:
Perhaps it would be better to prove that the current rules result in
easy explanations. What would the text of a bug filed on WordPress
look like? Let's assume you actually want them to fix it, not just
make a point.

The bug would request that Wordpress doesn't try to output XML for the text/html media type. That seems to be the problem here.

If the code for Wordpress fit on a page, that suggestion would be easy to implement.

As it stands now, it appear that several hundred lines of code would need to change. And in each case, the code would need to be aware of the content type in effect. In some cases, that information may not be available. In fact, that may not have been determined yet.

One way cross-cutting concerns such as this one are often handled is to simple capture the output and post-process it. Latchlan opted to do so with the WHATWG Blog. The first pass for things like this generally takes the form of simple pattern matching and regular expressions.

Often this evolves. What would be better is something that could take that string and produce a DOM, from which a correct serialization can take place.

Now, what type of parser would you use? HTML5's rules come tantalizingly close to handling this situation, except for a few cases involving tags that are self-closing...

- Sam Ruby

Reply via email to