W3C home > Mailing lists > Public > whatwg@whatwg.org > November 2006

[whatwg] Allow trailing slash in always-empty HTML5 elements?

From: Michel Fortin <michel.fortin@michelf.com>
Date: Thu, 30 Nov 2006 14:48:06 -0500
Message-ID: <D5EF0F30-50EC-4327-B48C-3007CF09360C@michelf.com>
Le 30 nov. 2006 ? 10:16, Henri Sivonen a ?crit :

> Without labels, I do think that regardless of how the HTML5 spec  
> turns out, WordPress has an architectural flaw in its methodology  
> of producing markup. Since the flaw is in the architecture, I am  
> not optimistic of it getting fixed in WordPress because it would  
> require a rewrite. I'm hoping that at some point, a better system  
> enters the market. Meanwhile, asking the WP developers to rewrite  
> theirs seems unproductive.

I concur with that. While it may be true that WordPress often gives  
valid XHTML1 markup, it can't be denied that the internal processing  
manipulates pseudo-HTML tag soup at almost every levels, that's not a  
good architecture if you ask me. Integrating Markdown correctly into  
the text system of WordPress is a big hack because of that; filters  
have to be inserted all around the place as workarounds for various  
issues. I've written on the subject if someone wants to dig deeper:

  <http://www.michelf.com/weblog/2005/wordpress-text-flow-vs-markdown/>

The best way someone could fix the resulting tag soup would probably  
be to pass the result through HTML Tidy. And it should be pretty  
straightforward since the tidy library has been part of PHP since  
version 5.

  - - -

For me, accepting /> in HTML could be an acceptable solution. It sure  
is a departure from what was accepted as HTML previously, but I see  
no point in trying to convince everyone to change (again) their  
markup for cosmetic reasons.

What is really important is that authors understand better that HTML  
must be served as text/html and that XHTML must be served with an xml  
media type. If the validator enforce that, then I think it'll be  
sufficient.

What really confused people with XHTML1 is that the validator accepts  
XHTML1 as text/html without complaining, without even checking that  
the document will do fine when parsed as HTML. If the validator tells  
someone that his <div/> is perfectly valid for XHTML1 as text/html,  
it's normal for that person to wonder why it doesn't work in the  
browser. That's confusing for authors, and that's exactly what we  
should avoid.


Michel Fortin
michel.fortin at michelf.com
http://www.michelf.com/
Received on Thursday, 30 November 2006 11:48:06 UTC

This archive was generated by hypermail 2.4.0 : Wednesday, 22 January 2020 16:58:50 UTC