ElementNode
class ElementNode extends AreaNode
HTML/XML element with attributes, content, and n:attribute support.
Properties
| $attributes | |||
| $selfClosing | |||
| $content | |||
| Tag[] | $nAttributes | ||
| $dynamicTag | |||
| $breakable |
Methods
__construct(string $name, Position|null $position = null, ElementNode|null $parent = null, string $contentType = ContentType::Html)
No description
Node|bool|null
getAttribute(string $name)
Returns the attribute value: plain string if static, Node if dynamic, true if it is a boolean or n:attribute, null if not found.
bool
is(string $name)
Checks whether the element has the given tag name (case-insensitive in HTML, case-sensitive in XML).
bool
isRawText()
Checks whether the element contains raw text (i.e., is a