tags method (all, anchors, areas, ...)
Returns a NodeList collection that contains all elements from the current collection with the specified tag name.
The tags method works on collections like the getElementsByTagName method on elements.
You can find the related objects in the Supported by objects section below.
|Required. String that specifies the tag name to look for.|
Returns a NodeList collection filled with the matching elements. The elements in the returned collection are in source order.
Example HTML code 1:
This example illustrates the use of the tags method:
Did you find this example helpful?
User Contributed Comments