Remember: Block-level tags add a line break before and after the tag. Inline styles affect how text appears without adding breaks or extra spaces.Most of the tags you've learned so far have been block-level elements. This means they cause a line break before and after the tag, such as the
<h1>tag or the
<p>tag. Another kind of tag is an inline-level element, which changes how text appears without adding line breaks. The next sections describe two of these types of tags.
Try It: Use inline styles, such asThe
Inline Styleswill appear as:
We <em>really</em> <strong>really</strong>
hope you are enjoying this lesson!
We really really hope you are enjoying this lesson!
<em>stands for emphasis and indicates the text inside this container tag should be emphasized, or stressed, a lot like when you put an exclamation point after a sentence. For example, in this sentence, the word sentence is emphasized. Most browsers indicate emphasis by italicizing the text.
<strong> tag is just like the
only even more so. So if you really want to strongly emphasize
something, you would use the
<strong> tag. Most browsers
indicate strong emphasis by bolding the text.