Search within TutorialsPark

CSS Pseudo Class Selector :not


Negates a selection


Definition and Notes.

1. CSS Pseudo Selector :not(<selector>) selects and styles every element that is not the match for the selection. i.e inversion of the selection

2. p:not(.demo) will select and style every <p> element that does not contain the class "demo".


Pattern:

CSS :not(<selector>)Pseudo Class selector. internetexplorer safari firefox opera chrome

View in Splitscreen»

Code-Editor:

Note:Use this to target elements that do not match the selector condition.


Related Examples.