JavaScript Reference/Javascript Properties/documentElement — различия между версиями
Admin (обсуждение | вклад) м (1 версия) |
|
(нет различий)
|
Текущая версия на 11:21, 26 мая 2010
"documentElement" Example
<source lang="javascript">
<html> <body> <button onClick="alert(document.documentElement.nodeName);">Root Node</button> </body> </html>
</source>
"documentElement" is applied to
<source lang="javascript">
+----------------+--------------------------------------------------------------+ | Applied_To |document | +----------------+--------------------------------------------------------------+
</source>
"documentElement" Syntax and Note
<source lang="javascript">
Note: Read-only property. Returns the HTML element that contains all the content.
Syntax:
document.documentElement
</source>