4 ms·
It's probably even easier to just put inline styles on every row, but neither of those practices are going to result in maintainable markup. By adding classes
by slang800 12y ago
It's probably even easier to just put inline styles on every row, but neither of those practices are going to result in maintainable markup.
By adding classes for the singular purpose of styling them, you tie your markup to the appearance of the web page. Instead, classes should be used to further describe the contents of elements in relation to each other. Then all the presentational rules can be kept in CSS, and selectors can be used to style based on the meaning of the content.
This means the style of the page can change without modifying the markup. And if the styles are written well enough, they can be applied to any (sane) markup.
Oh and +1 for colgroup!