Selectors in CSS

Selectors in CSS

Q1. What are the selectors in CSS and it's type ?

Selectors Means selection of the HTML tags either one or more than one . even we can select the tag of HTML particularly and in group.

Q Why are we using selectors in CSS?

we can use selectors for design and giving styling on that html tag for increasing more beautiful .

Selectors are....

1). simple selector

2).Combinators Selectors.

3). Attribute Selector.

4). Pseudo-class Selector.

5). Pseudo-Elements Selector

Note:-Css selectors cannot use in inline CSS

we will be using it internsl CSS and External CSS.

  1. Simple Selector:- it has 5 more selectors

  2. a). Universal Selector.

  3. b). Class selector

  4. c). ID selector.

  5. d). Elements selector.

  6. e). selector list

  7. a). Universal selector:- it mainly used to set everything Zero and start from zero after used it the programmer decides everythings like :- padding,margin etc.

  8. b).Class selector:-