ARTICLE AD BOX
Can I add CSS-generated text to an element with ‘content:’ and somehow give it a color?
For example, in pseudo-HTML, the result might look like the following:
[red]"[/red] element-text [red]"[/red] so in this example, the CSS-generated quotes only are red and the main core text of the element is black.I want to be able to, using CSS's ::before or ::after, color only a portion of the text - like:
.example::before { content: [red]"[/red] non-red text [red]"[/red] }Note that no javascript is permitted in this particular situation, only pure, straight CSS.
