What's the difference between em/i and strong/b
I learned HTML before and I always learned to italicize with the tags and makes things bold with tags. Where are the and tags coming from? Why they are teaching this way?
I think that the whole point of modern development is to try to separate the presentational from the structure and logic. That’s why we have an html file, a css file and a js file.
The strong tag doesn’t mean bold, it just denotes the importance of the sentence in the context, the same goes for the emphasis tag.
B an I are not deprecated in html5 just because the thought behind html5 development was to have a strong backward compability. But it’s not recommended.
This is a good in-depth explanation of the issue, if anyone wants to read more: http://stackoverflow.com/questions/271743/whats-the-difference-between-b-and-strong-i-and-em
General consensus is that ‘em’ and ‘strong’ should be used as they indicate semantic meaning (i.e. ‘This text or word is more important than the others’) as well as how the text should look (i.e. ‘This word should be bold or italic’), whereas ‘b’and ‘i’ only do the latter.
As the link explains, ‘b’ and ‘i’ may suffice for the web, but they may cause intelligibility problems for HTML pages displayed on other devices such as PDAs and mobiles.
In fact, there’s only some formal semantic difference that is unseen to the user, so you can use any tag you want (I prefer using “i” and “b” because they are short). “b” and “i” tags are NOT deprecated in HTML5 and I think that using CSS for making text bold or italic is lame.
I wrote about formal semantic difference in my comment. Sebastian says exactly the same - that ‘strong’ is not just for making bold but for also for some hidden sense that can be read while checking the source code (cause ordinary user won’t see whether you used ‘strong’ or something else and won’t understand what the use of ‘strong’ means - he doesn.t need to learn html to visit your site). All right then - I’ll use ‘b’ - an ordinary tag for making text bold. I don;t have a need in user who tries to hide some hidden sences. :)
And, yes, I’ll prefer shortcuts and guess, someday ‘strong’ and ‘em’ will be deprecated - not ‘b’ and ‘i’. ;)
Popular free courses
- Free Course
Learn SQLIn this SQL course, you'll learn how to manage large datasets and analyze real data using the standard data management language.Beginner friendly,4 LessonsLanguage Fluency
- Free Course
- Free Course
Learn HTMLStart at the beginning by learning HTML basics — an important foundation for building and editing web pages.Beginner friendly,6 LessonsLanguage Fluency