top | item 5466502

(no title)

zopticity | 13 years ago

Nope, you're wrong. <b> is actually still being used to differentiate between <strong>. <strong> is used for accessibility reasons (making the words enunciate with emphasis, while <b> just makes the words bold by default). If you want to bold a part of the sentence without having emphasis, you'll need to use <b>.

discuss

order

saraid216|13 years ago

I'd use <span style="font-weight: bold" /> for making something bold. Because that's a styling thing, so I use a style sheet.

I could even use <strong style="font-weight: normal" /> if I wanted to emphasize something without making it bold. Because that has a functional purpose with screen readers, and isn't strictly a styling thing.

Evbn|13 years ago

What's the difference between <strong> and <em>.

Em is for emphasis.

stan_rogers|13 years ago

<em> is for intonational emphasis, the way you'd give a little extra stress on a word when you are speaking. <strong> is an indicator of importance, and may not correspond to intonational emphasis in spoken language.

As for the older tags, they were deprecated in XHTML, but have been redeemed in HTML 5. <i> is used for elements that are traditionally set it italics but are neither emphasized nor citations. Often that will be foreign words (where one ought to use a lang attribute). Similarly <b> is used to indicate elements that are traditionally set in bold face, but which do not indicate importance (as headings or <strong> in running text would do). Both are better than the semantically-meaningless <span> tag, and vastly better than misusing the <em>, <cite> and <strong> tags for their presentation effects.