CSS Rare Selector

If you are a web developer then you have used many css selector to give styling to your web page. In this blog we are going to explore some rare but usefull selector of css


1. Adjacent Sibling Selector (+)

In simple way it select the next first sibling respectively tag.


2. General Sibling Selector (~)

Where + select next first sibling but ~ select all next sibling after tag.


Pseudo class selector

3. :active

Select all active link


4. :checked

Select all chcked input


5. :empty

Select all element that has no children


5. :enabled

Select all enabled input


6. :first-of-type

Select all element that is first element of its parent


7. :last-of-type

Select all element that is last element of its parent(opposite of first-of-type)


8. :focus

Select all input element that has focus


9. :in-range

Select all input element that has a value in a range


10. :invalid

Select all input element that has a invalid value


10. :lang(language)

Select all element with a lang attribute value start with language

On August 6, 1991, without fanfare, British computer scientist Tim Berners-Lee published the first-ever website while working at CERN, the huge particle physics lab in Switzerland