some selectors to design HTML page πππ
SELECTORS
IN CSS WITH DESCRIPTION :-
CSS selectors are used to select the
content you want to style. Selectors are the part of CSS rule set. CSS
selectors select HTML elements according to its id, class, type, attribute etc.
|
selector |
description |
|
1.
Type selector h1{} |
h1 selects all elements of any type with class h1 inside of the
body element |
|
2.
Universal *{} |
universal selector ( * ) matches
elements of any type |
|
3.
Class selector .box{} |
|
|
4.
Id selector #unique{} |
The id selector uses the
id attribute of an HTML element to select a specific element |
|
5.
Attribute a[title]{} |
The |
|
6. Pseudo class p:first-child{} |
The :first-child selector allows you to target the first element immediately inside another
element |
|
7.
Pseudo element P:first-line{} |
In CSS, the ::first-line pseudo-element can
only have an effect |
|
8.
Child combinator article>p |
A child combinator describes a childhood relationship between two elements. |
|
|
|

Comments
Post a Comment