CSS - How to apply style changes only to specific text inside a <p> tag?
When you want to apply specific CSS inline style to some text inside a HTML <p> </p> tag, you can use <span> tag.
<p>This is a <span style="color: navy;">sample text </span>with css applied to span. </p>
The above code will look like the following text in the browser:.
This is a sample text with css applied to span.