
On 10/14/2011 3:32 PM, Scott Olson wrote:
On Fri, Oct 14, 2011 at 2:59 PM, Lee Passey <lee@novomail.net <mailto:lee@novomail.net>> wrote:
... the W3C whose advice is "use <em> instead of <i>", when in fact it should be "use <em> for emphasis and <i> to contrast a span of text from the surrounding text."
I think they actually recommend using CSS where <em> isn't appropriate.
Well, I think that's what they /should/ recommend, but I don't think that's the message that's getting out. And the messages that /are/ getting out are mixed. For example, the CSS 2.1 specification notes: "CSS gives so much power to the "class" attribute, that authors could conceivably design their own "document language" based on elements with almost no associated presentation (such as DIV and SPAN in HTML) and assigning style information through the "class" attribute. Authors should avoid this practice since the structural elements of a document language often have recognized and accepted meanings and author-defined classes may not." In other words, don't use <span> or <div> where some other element already covers it. Or perhaps more explicitly, don't use <span class="italic"> when you could use <i>. I guess it could be argued that since <i> is deprecated the foregoing note doesn't apply, but that's by no means clear. Another example: Over the course of the past year I've been fighting with Adobe's RoboHelp to create an HTML-based help system. In the WYSIAWYG editor Adobe has created, when you select a span of text and select "italicize" the HTML code gets created with <em>, not <span class="italic">. The same is true of bold, which is automatically encoded using <strong>. If non-emphasized font changes are supposed to be marked up with <span> and not <em> or <strong>, it seems that Adobe didn't get the memo. So, by show of hands: how many here believe that you should always use <em> when you want an italicized presentation? Now I'm not saying you're wrong -- in fact, I think you're right. But there's a whole lot of confusion about this which is very pervasive, and a lot more clear public statements from the w3c are necessary.