MCQ Single Best Answer Easy

QWhat is returned by the nodeName of the nodeType Document?

ID: #5193 Javascript DOM & Event Handling MCQ 201 views
Question Info
#5193Q ID
EasyDifficulty
Javascript DOM & Event Handling MCQTopic

Choose the Best Option

Click any option to instantly check if you're correct.

  • A doctype name
  • B target
  • C #comment
  • D #document
Correct Answer: Option D

Explanation

The nodeType Document's nodeName returns #document.
If the node is an element node, the tag name will be returned by the nodeName property.
The nodeName property returns the name of the attribute if the node is an attribute node.

Share This Question

Challenge a friend or share with your study group.