Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community!
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trial
hoppy bouasavanh
Courses Plus Student 1,791 Pointswhat does *::after and *::before mean for universal selector?
?
2 Answers

Maor Tzabari
1,762 PointsOh, sorry I didn't see that, I'm not familiar with that either, usually * means ALL, but in this case I don't think it does something

Maor Tzabari
1,762 PointsLet's say you have this markup:
<div class="price">534</div>
<div class="price">120</div>
<div class="price">421</div>
and whoever build it forgot to put the dollar sign since it's a price (in my example). instead of putting the dollar 3 times in the HTML, you can define it once if you want it to be before or after:
.price::before{
content: " $ ";
}

hoppy bouasavanh
Courses Plus Student 1,791 Pointsthx q. but for universal (*), what does after and before mean for universal?