When I learned HTML, <b> </b> was the tag to make text bold, but now I see <strong> appearing more and more, to the point that the drupal CMS that I’m using won’t recognise <b> unless I change the setting to allow Full HTML, whereas <strong> is allowed under “basic” HTML.
CSS is the new black. Most likely your software recognizes “strong” not because it’s the standard, but because they didn’t think of it when they put in their “deprecated” check.
“strong” is the standard now. The whole point of moving towards semantic markup with separate CSS is that style information should not be in the markup. So the trend is to move away from tags that say “this is bold” to tags with semantic meaning like “this is emphasized” or “this is strong” and then CSS and/or browser defaults can specify the display characteristics.
Why the choice to not make <b> the standard code for “use the defined CSS setting for emphasized text” ? Why make a new keyword, instead of retooling the “traditionnal” one everybody’s used to ?
Because the industry is trying to emphasize that content and NOT formatting is what belongs in the plain HTML. with <b> you are saying that you want that sentence to be bold. You are describing formatting. with <strong> you are saying that the content in between the tags needs to be emphasized. You are describing content, not applying formatting.
You can’t “re-tool” something that isn’t centrally controlled.
As a deep design philosophy, everything has to continue to work the way it used to almost forever. New stuff can be added but old stuff, both good and bad, must linger for decades.
<strong> has actually been around almost since the beginning. The early days of the web & html were characterized by a massive explosion of barely trained short-sighted non-professional people writing html. And they all-but-universally went for the path of least resistance.
In an era when <b> meant “bold”, and <strong> meant, “something emphasized according to the user’s browser brand and version, probably bold, but maybe not”, anyone who wanted picture-perfect results for their precious advertising would be a fool to use <strong>.
One reason style information should not be included in HTML is that HTML is not always rendered visually. It might be rendered, for example, by speech synthesis, in which context ‘bold’ and ‘italic’ are meaningless, but ‘strong’ and ‘emphasised’ are not.
From a practical point of view, I can’t think of a single (visual) browser that doesn’t render strong as bold. That leaves two possibilities: strong can be something other than bold in the designer’s stylesheet (where the designer still has control anyway), or it can be something other than bold in an overriding user stylesheet, which, let’s face it, a user isn’t likely to do unless they need to for accessibility reasons. And any advertiser would be a fool to place making their advertisement look right above ensuring users can actually understand it.
I’ve recently run into this with <i> and <em>. It’s very annoying. But now it seems like the standard is to define a CSS class called “emphasized” (or whatever) and instead of doing something like “Tim <i>hates</i> crack” or “Tim <em>hates</em> crack”, doing something like “Tim <span class=“emphasized”>hates</span> crack”.
Interesting, but … if you have a lot of italics, that’s gonna expand the ol’ filesize significantly.
Standards are written by committees. The end product is a piece of paper that’s just a series of compromises left for the software engineers to turn into a working implementation. The idea that it should make sense, be consistent, be easy to implement, be logical, etc is none of that committees concern.
Why on earth would anyone do that? <em> is a perfectly acceptable tag with respect to content/layout separation – it indicates semantics without indicating layout. In fact, it provides the exact same semantics as <span class=“emphasized”>, and it’s just as stylable.
I assure you that is not the standard usage. The proper way to indicate emphasis in markup is with <em></em>. Anybody who uses <span class=“emphasized”> obviously has just enough knowledge to be dangerous, but really has no idea what they’re doing.
Nitpick: <span> has no semantics, it’s for styling purposes only. If you want to indicate emphasis, you should use <em>. It’s a lot shorter too, which is nice.
There’s a perfectly good practical reason not to stick with <b> - it’s deprecated! Browsers currently support deprecated tags, but there’s no guarantee that they will in future.
It’s not wrong; you’re just using an older version of HTML when you do that. Using an older version of HTML is kind of like using an older version of a Microsoft Word. You can write it, sure, but if someone else has to open it with a newer version, it’s not guaranteed to work properly. We can still open documents from Word 97 in Word 2007, but what about documents from the original Word in 1983?
In 10 years time, the web will work very differently, just as it works very differently now to how it worked 15 years ago. We’re currently at the tail end of Web2.0. Web3.0, or Semantic Web, is already peeking through the curtains trying to make its entrance. The markup standard has to keep pace to reflect this, especially since Semantic Web isn’t a final goal, but a stepping stone to Web4.0 - Intelligent Web. Because the web is not final, but rather is still changing and developing, it only makes sense that the standards associated with the web should also develop.