DOM Objects Flashcards

You may prefer our related Brainscape-certified flashcards:
1
Q

accessKey

A

Sets or returns the accesskey attribute of an element

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

appendChild()

A

Adds a new child node to an element

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

attributes

A

Returns a NamedNodeMap of an element’s attributes

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

blur()

A

Removes focus from an element

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

childElementCount

A

Returns a node list of all the elements child elements

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

childNodes

A

Returns a node list of an element’s child nodes

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

children

A

Returns an HTMLCollection of an elements child elements

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

classList

A

Returns the class name(s) of an element

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

className

A

Sets or returns the value of the class attribute of an element

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

click()

A

Simulates a mouse-click on an element

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

clientHeight

A

Returns the height of an element, including padding

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

clientLeft

A

Returns the width of the left border of an element

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

clientTop

A

Returns the width of the top border of an element

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

clientWidth

A

Returns the width of an element, including the padding

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

cloneNode()

A

Clones an element

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

closest()

A

Search the DOM tree for the closest element that matches a CSS selector

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
17
Q

compareDocumentPosition()

A

Compares the document position of two elements

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
18
Q

contains()

A

Returns true if a node is a descendent of a node

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
19
Q

contentEditable

A

Sets or returns whether the content of an element is editable or not

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
20
Q

dir

A

Sets or returns the value of the dir attribute of an element

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
21
Q

exitFullScreen()

A

Cancels an element in full screen mode

22
Q

firstChild

A

Returns the first child node of an element

23
Q

focus()

A

Gives focus to an element

24
Q

getAttribute()

A

Returns the value of an element’s attribute

25
Q

getBoundingClientRect()

A

Returns the size of an element and its position relative to the viewpoint

26
Q

getElementsByClassName()

A

Returns a collection of child elements with a given class name

27
Q

getElementsByTagName()

A

Returns a collection of child elements with a given tag name

28
Q

hasAttribute()

A

Returns true if an element has a given attribute

29
Q

hasAttributes()

A

Returns true if an element has any attributes

30
Q

hasChildNodes

A

Returns true if an element has any child nodes

31
Q

id

A

Sets or returns the value of the id attribute of an element

32
Q

innerHTML

A

Sets or returns the content of an element

33
Q

innerText

A

Sets or returns the text content of a node and its decendants

34
Q

insertAdjacentElement()

A

Inserts a new HTML formatted text at a position relative to an element

35
Q

insertAdjacentHTML()

A

Insert an HTML formatted text at a position relative to an element

36
Q

insertAdjacentText()

A

Inserts text into a position relative to an element

37
Q

insertBefore()

A

Inserts a new child node before an existing child node

38
Q

isContentEditable

A

Returns true if an element’s content is editable

39
Q

isDefaultNamespace()

A

Returns true if a given namespaceURI is the default

40
Q

isEqualNode()

A

Checks if two elements are equal

41
Q

isSameNode()

A

Checks if two elements are the same node

42
Q

isSupported()

A

Returns true if a feature is supported on the element

43
Q

lang

A

Sets or returns the value of the lang attribute of an element

44
Q

lastChild

A

Returns the last child node of an element

45
Q

lastElementChild

A

Returns the last child node of an element

46
Q

matches()

A

Returns true if an element is matched by a given CSS selector

47
Q

namespaceURI

A

Returns the namespace URI of an element

48
Q

nextSibling

A

Returns the next node at the same node tree level

49
Q

nextElementSibling

A

Returns the next element at the same node tree level

50
Q

nodeName

A

Returns the name of a node