• Just installed WP 2.0.2, been using WP 1.5 for a while, anyways, I found the the new rich text editor in WP 2.0.2 generates some invalid Strict XHTML:

    The rich text editor uses the <strike> tag for strikethrough. in XHTML Strict, the <strike> tag has been dropped. The rich text editor should be fixed to use the <del> tag instead, so it will validate Strict.

    Also, I notice there is no underline button in the rich text editor and I believe there should be one, because it’s there in the standard HTML editor. If an underline button is added, it should offcourse use the <ins> tag, not the deprecated <u> tag.

    I went straight back to the standard HTML editor, but it would be nice to see it generate better XHTML for those wysywig people out there.

Viewing 4 replies - 1 through 4 (of 4 total)
  • WP has never conformed to Strict. A user would need to edit files to render output as Strict.

    Underline is on the way and it does use <u> .. it’s the right forum though for the issue to be seen.

    if an underline button is added, it should offcourse use the <ins> tag not the deprecated <u> tag

    If we’re going to be pedantic, the ins tag is technically not a replacement for the u tag; the u tag is for underlines whilst the ins tag is to semantically markup inserted items. Using it for underlining is as semantically bad as the old practice of using blockquotes for indentation. The webstandards mechanism of underlining is via CSS; the pragmatic way is via the <u> tag.

    Excuse my little digression:)

    Thread Starter robvdl

    (@robvdl)

    I know, but you don’t have much choice, the <u> tag has been deprecated completely in XHTML 1.0, and that’s not only in Strict.

    The only alternative way would be to use a style sheet and use a <span class="underline">, but that just seems more work to me.

    Semantic or not, I am going to continue using the <ins> and <del> tags, because they should have never removed the <u> and <strike> tags, and why did they decide to keep the <strong> and <em> tags then?? I mean if <u> has been removed, because it represents layout too much, why did they not remove <strong> and <em>? because they repesent layout just as much as the <u> tag does if you ask me.

    Seems just like a silly mistake in the XHTML design to me.

    I mean if <u> has been removed, because it represents layout too much, why did they not remove <strong> and <em>? because they repesent layout just as much as the <u> tag does if you ask me.

    You’d be wrong, though. The <b> and <i> tags are the equivalent layout tags. The <strong> and <em> tags are semantic, representing strong and emphatic statements respectively.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘WordPress uses some bad XHTML tags’ is closed to new replies.