Re: Cleaning House

Maurice wrote:
> <p class=MsoNormal>Abcd <i><u>efghijk lmnop <b>qrs</b></u></i><span
> style='font-style:normal'><u><b> tuv</b></u></span><u>
> wxyz<o:p></o:p></u></p>
> 
> Spent a couple minutes randomly highlighting portions of a paragraph in Word
> and bold/italics/underlining parts of it.
> 
> I can't seem to get it to output the often used example of:
> 
> <b> this is <i> a sentence </b> made of words</i>

That kind of thing happens more when authors hand code and forget to 
close an element, or just don't realise that things should be nested 
properly.  I don't know of any WYSIWYG editor that will output badly 
nested markup like that.

> Could we get some feedback from microsoft why they use <b> instead of
> <strong>? 

When you use the B button, that's what you get.  However, if you use the 
Styles and Formatting task pane (at least in Office XP or 2003), there 
are a whole bunch of HTML related semantics that can be added to the 
list from the customisation dialog.  There are predefined styles called 
"Strong", "Emphasis", "HTML Acronym", "HTML Cite", "HTML Code", "HTML 
Definition", "HTML Keyboard", "HTML Preformatted", "HTML Sample", "HTML 
Typewriter", "HTML Variable" and "Heading 1" to "Heading 6".

If you use those, and then export to HTML, you will get the appropriate 
elements in the final document.

> Also, they put spans all over the place. They could have just used spans
> with styles instead of b,I,and u tags.

What advantage would there be in using <span style=""> over <b> or <i>?

-- 
Lachlan Hunt
http://lachy.id.au/

Received on Friday, 4 May 2007 09:22:33 UTC