View Full Version : Changing text styles with CSS when the text can't be tagged as <p> or a heading

10-26-2011, 10:21 PM
In what html tag do I specify inline CSS styles?

In the simplest case, I want to change the text colour of some words in a paragraph, so I do something like:

<tag style="color:#D0D0D0;">Start of paragraph.</tag> Unstyled middle of paragraph. <tag style="color:#D0D0D0;">end of paragraph</tag>

My question is: what html tag do I put these styles in? Not everything is a <p> or <hx>; what's the equivalent to those for just text?

10-26-2011, 11:09 PM
<span> is what you're looking for...