In the last article, we learned about combinators in CSS which helps to select elements in various fashions in a very easy way. You are going to use them frequently in your web development.
You must have noticed, on various websites the if you have already visited a particular link, it shows up in a different color. Also, when you hover over buttons, they show various effects like a change in color, etc. In today's article, we are going to learn the same using pseudo-classes.
Let's begin...
property: value;
}
You must have noticed, on various websites the if you have already visited a particular link, it shows up in a different color. Also, when you hover over buttons, they show various effects like a change in color, etc. In today's article, we are going to learn the same using pseudo-classes.
Let's begin...
What are Pseudo-classes?
Some of the elements in HTML like a link, div or paragraphs have some special states which can be accessed by using pseudo-classes.Syntax
selector: pseudo-class {property: value;
}
Various Pseudo-classes related to links
The best way to use pseudo-classes is on the element link. Let's see how...Using pseudo-classes with CSS selectors
That's all for today. In this article, we take some basic look at pseudo-classes and seen some very useful pseudo-classes. In next article, we are going to learn some very handy pseudo-classes.
Till then #keepCoding.
Comments
Post a Comment