0 points

CSS - Before


dashboard

Sat Oct 24 2020 21:21:10 GMT+0000 (UTC)

Posted by @Carouan #css #before

<!DOCTYPE html>
<html>
<head>
<style>
p::before { 
  content: "Read this -";
  background-color: yellow;
  color: red;
  font-weight: bold;
}
</style>
</head>
<body>
​
<p>My name is Donald</p>
<p>I live in Ducksburg</p>
​
</body>
</html>
​
content_copy Copy

https://www.w3schools.com/cssref/tryit.asp?filename