Home > Article > Web Front-end > JavaScript learning bits and pieces_javascript skills
By using the getElementById() and getElementsByTagName() methods
By using the parentNode, firstChild and lastChild properties of an element node
There are two special document properties that can be used to access the root node:
document.documentElement
document.body