Lastly, text added via the CSS content property is not inserted into the DOM, so it can't be acted on later by Javascript, etc. I agree that it should not be used in general, and certainly should not be used for this purpose. +1
–
Jacob MattisonJun 23 '10 at 14:05

5

In certain contexts, the use of the content property could be stylistically correct. For instance, adding a comma after certain pieces of content: <span class="city">New York</span><span class="state">NY</span> .city:after { content: ", "; } So, it's not always wrong, but it's not by any means recommended.
–
Ryan KinalJun 23 '10 at 15:56

5

One useful example is putting colon (:) after labels or asterisk (*) after required fields. It can be agreed that these are just presentation details and a screen read should not read 'colon' or 'star' as part of the content.
–
andhoMar 18 '13 at 10:50