I don’t have access to modify the source html and the classes cover such a large span of things, I’m having trouble adding to it as I want.
I’m trying to add text to the area that already has text.
Tried the following but it does nothing.
.content div:firstchild:after { content: 'Test'; }
When I do the following, it adds the text but it adds it numerous times because there are numerous divs and other elements (I’ve tried to add it directly into the table, after b, etc)
.content div:after { content: 'Test'; }
2
Answers
Your CSS selector has a typo in it,
:firstchild
should be:first-child
.This should do what you need it to do:
With the
:before
and:after
selectors you specify which content should be inserted before (or after) the content inside of that element. Input elements have no content.