Page is a not externally linkable
- Code, Content, and Presentation
-- HTML
---- <b> tag verses <strong>


encyclo - 6:13 pm on Nov 30, 2004 (gmt 0)


ProfMoriarty, there is some sense in making a "bold" class when you want to avoid hardcoding a particular style into the HTML, as whilst with CSS you could always do a
b {font-weight:normal;} later, for non-CSS user agents, the bold will always show.

However, that is not always a problem, so in those cases, using <b></b> is a good idea rather than <span class="bold"></span>.

One other advantage of <b> and <i> are that, because they are semantically meaningless, you can use them as replacements for <span> whilst still making that style distinction for non-CSS user agents. Here's a (rather poor) example:

<h1>My title</h1>
<h2>My subtitle</h2>
<p>Date of publication: <b class="date">January 1st, 2005</b></p>

and with the CSS:

b.date {
font-weight:normal;
color:red;
}

As your date is not important, you don't want to use a hx heading, but if you used a <span>, it would remain indistinguishable from a normal paragraph in a non-CSS environment.


Thread source:: http://www.webmasterworld.com/html/9181.htm
Brought to you by WebmasterWorld: http://www.webmasterworld.com