Unfortunately, you cannot control the size of the image when specifying it through the content, but you can, if you use it as a background:
.with_before:before{ content:''; background-image: url('http://i.stack.imgur.com/CAAFj.jpg'); background-size: 100% 100%; width: inherit; height: inherit; display: inline-block; }
check jsFiddle
And for your question, why we canβt generate the generated content: We canβt, because the generated content is displayed in the generated field, and you can style this field, but not the content.
links:
note that different browsers have very different behaviors.
Tomzan
source share