Select.tags() (Method)

A method for retrieving collections of objects belonging to a particular class and which are a subset of the all[] collection for this object.

Availability:

JScript - 3.0
Internet Explorer - 4.0
Property/method value type:Collection object
JavaScript syntax:IEmySelect.tags(aTagName)
Argument list:aTagNameThe name of a tag to be filtered

This is a technique that only works in MSIE. The tags() method is used on all manner of collections.

The collection is traversed and all objects are examined to see if they were created by an HTML tag that is the same as that specified in the argument.

The argument must always be specified in upper case and the resulting collection will contain all objects of that type selected from the receiving collection object.

You can then manipulate the sub-set collection in the normal way, accessing items within it by index or by other means.

See also:Collection.tags()