dcsimg
 

Add Text After a Particular HTML Element Using CSS

Thursday Dec 20th 2018 by Srinath MS

Language: Web, Expertise: Beginner - See how to add text via CSS to the end of a particular HTML element.

Use the :after selector to add text after the element. Please see below for an example.

If you want to add text, such as 'Click the email link at the bottom of the page for feedback,' at the end of every div, you would simply add the following in the CSS.

div:after{ 
content: "Click the email link at the bottom of the page for feedback";
}
Home
Mobile Site | Full Site