Ask Question
25 January, 08:15

State one similiarity between the returned value of getElementsByTagName () and getElementsByClass ()

+1
Answers (1)
  1. 25 January, 10:01
    0
    The return type of both the methods is a Live HTMLCollection.

    Explanation:

    Both the methods getElementsByClassName () and getElementsByTagName () returns a Live HTMLCollection. Both the methods result in the collection of elements according to the method name. The method getElementsByClassName () results in the elements with the given class name. The method getElementsByTagName () results in the elements with the given Tag name. As stated above both the methods returns HTMLCollection which are live. That means the methods take care of the changing tag names and class names. If there are any updates to the class names and tag names, the list gets updated accordingly.
Know the Answer?
Not Sure About the Answer?
Find an answer to your question ✅ “State one similiarity between the returned value of getElementsByTagName () and getElementsByClass () ...” in 📘 Computers and Technology if you're in doubt about the correctness of the answers or there's no answer, then try to use the smart search and find answers to the similar questions.
Search for Other Answers