How to use pseudo elements to add pictures to text in CSS
In this article Xiaobian for you a detailed introduction of "CSS how to use pseudo elements to add pictures on the text", detailed content, clear steps, details handled properly, I hope this "CSS how to use pseudo elements to add pictures on the text" article can help you solve doubts, the following follow the editor's ideas slowly in-depth, together to learn new knowledge bar.
Use pseudo elements to add a picture to the text
H2::before {
Content: url ('. / vue.png')
}
This is a title.
:: before pseudo-element inserts content before the content of an element.
This is a title.
The selected characters change color
::-moz-selection {/ * Code for Firefox * /
Color: red
Background: pink
}
:: selection {
Color: red
Background: pink
}
Please select the text on this page:
This is a paragraph.
This is the text in the div element.
Note: Firefox supports the alternative::-moz-selection attribute.
Read this, the "CSS how to use pseudo elements to add pictures to the text" article has been introduced, want to master the knowledge of this article also need to practice and use in order to understand, if you want to know more about the article, welcome to follow the industry information channel.