Search within TutorialsPark

CSS Pseudo Class Selector :root


Selects the root element in the document


Definition and Notes.

1. CSS Pseudo Selector :root selects the root element of the document, and for HTML document it is always the <html> element.

2. Its mainly useful when used with XML document, within its stylesheet.


Pattern:

CSS :rootPseudo Class selector. internetexplorer safari firefox opera chrome

View in Splitscreen»

Code-Editor:

Note:Use it to assign higher specificity to HTML element, to set property that cannot be altered.


Related Examples.