DOM Tree
- Node
- Document
- HTMLDocument
- CharacterData
- Text
- Comment
- Element
- HTMLElement
- HTMLHeadElement
- HTMLBodyElement
- HTMLTileElement
- HTMLParagraphElement
- HTmMLInputElement
- HTMLTableElement
- ...etc
- HTMLElement
- Attr
- Document
### 태그를 찾을수 있다
<!DOCTYPE html>
<html lang="en" dir="ltr">
<head>
<meta charset="utf-8">
<title></title>
</head>
<body>
<a id="anchor" href="http://opentutorials.org">opentutorials</a>
<ul>
<li>HTML</li>
<li id="list">CSS</li>
<li>JavaScript</li>
</ul>
<input type="button" value="button"/>
<script>
var target = document.getElementById('list');
console.log(target.constructor.name);
var taget = document.getElementById('anchor');
console.log(target.constructor.name);
var taget = document.getElementById('button');
console.log(target.constructor.name);
</script>
</body>
</html>
'HTML 참고서 > HTML 생활코딩 Youtube' 카테고리의 다른 글
12.JavaScript API (0) | 2020.04.16 |
---|---|
11.JavaScript Collection (0) | 2020.04.14 |
9. JavaScript jQuery (0) | 2020.04.12 |
8. JavaScript 제어대상 찾기 (0) | 2020.04.12 |
7. JavaScript 창제어 (0) | 2020.04.12 |