The forums ran from 2008-2020 and are now closed and viewable here as an archive.
Home › Forums › Other › How you do stylize text?
When you need to change text with a css class what do you use when you <p class=" "> isn’t an option? the paragraph tag treats the text like a block causing the line breaks.
So, other than a <div> or <p> what do you guys resort to?
Note: I’m not asking how to do it. I was curious how other do it :)
Depends on the purpuse.
Sometimes I use <em>, <strong> and indeed, <span>
<strong> or <em> doesn’t always have to be bolded or Italicized. You can undo that in css.
Somtimes using <em> and <strong> is appropiate (semantics), but sometimes it can also be non-semantic.
But long story short, a <span> always does the job, and if you want your span to be bold aswell, then you can always use <strong>, saving you a line of CSS (same goes for italic text, using <em>)