Introduzione
PHP Manual
PHP Manual»DOM»Dom\HTMLCollection

The Dom\HTMLCollection class

(PHP 8 >= 8.4.0)

Represents a static set of elements. It is similar to Dom\NodeList, but restricted to Dom\Element nodes.

class Dom\HTMLCollection implements IteratorAggregate, Countable {
/* Proprietà */
public readonly int $length;
/* Metodi */
/* Not documented yet */
}
length

The number of elements.

Versione Descrizione
8.5.0 Cloning a Dom\HTMLCollection object now fails.

Nota:

The DOM extension uses UTF-8 encoding when working with methods or properties. The parser methods auto-detect the encoding or allow the caller to specify an encoding.

To Top