Element Object Methods & Properties 2 Flashcards

1
Q

Returns the last child node of an element

A

element.lastChild

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

Returns the last child element of an element

A

element.lastELementChild

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

Returns the namespace URI of an element

A

element.namespaceURI

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

Returns the next node at the same node tree level

A

element.nextsibling

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

Returns the next element at the same node tree level

A

element.nextElementSibling

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

Returns the name of a node

A

element.nodeName

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

Returns the node type of a node

A

element.nodeType

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

Sets or returns the value of a node

A

element.nodeValue

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

Joins adjacent text nodes and removes empty text nodes in an element

A

element.normalize( )

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

Returns the height of an element, including padding, border and scrollbar

A

element.offsetHeight

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

Returns the width of an element, including padding, border and scrollbar

A

element.offsetWidth

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

Returns the horizontal offset position of an element

A

element.offsetLeft

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

Returns the offset container of an element

A

element.offsetParent

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

Returns the vertical offset position of an element

A

element.offsetTop

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

Returns the root element (document object) for an element

A

element.ownerDocument

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

Returns the parent node of an element

A

element.parentNode

17
Q

Returns the parent element node of an element

A

element.parentElement

18
Q

Returns the previous node at the same node tree level

A

element.previousSibling

19
Q

Returns the previous element at the same node tree level

A

element.previousElementSibling

20
Q

Returns the first child element that matches a specified CSS selector(s) of an element

A

element.querySelector( )

21
Q

Returns all child elements that matches a specified CSS selector(s) of an element

A

element.querySelectorAll( )

22
Q

Removes a specified attribute from an element

A

element.removeAttribute( )

23
Q

Removes a specified attribute node, and returns the removed node

A

element.removeAttributeNode( )

24
Q

Removes a child node from an element

A

element.removeChild( )

25
Q

Replaces a child node in an element

A

element.replaceChild( )

26
Q

Removes an event handler that has been attached with the addEventListener( ) method

A

element.removeEventListener( )

27
Q

Returns the entire height of an element, including padding

A

element.scrollHeight

28
Q

Sets or returns the number of pixels an element’s content is scrolled horizontally

A

element.scrollLeft

29
Q

Sets or returns the number of pixels an element’s content is scrolled vertically

A

element.scrollTop

30
Q

Returns the entire width of an element, including padding

A

element.scrollWidth

31
Q

Sets or changes the specified attribute, to the specified value

A

element.setAttribute( )

32
Q

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

A

element.style

33
Q

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

A

element.tabIndex

34
Q

Returns the tag name of an element

A

element.tagName

35
Q

Sets or returns the textual content of a node and its descendants

A

element.textContent

36
Q

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

A

element.title

37
Q

Converts an element to a string

A

element.toString( )

38
Q

Returns the node at the specified index in a NodeList

A

nodelist.item( )

39
Q

Returns the number of nodes in a NodeList

A

nodelist.length