org.w3c.dom.Node.getAttribute
method

    public getAttribute(name as String) as String

Description

Returns an element attribute value when this node is an element.

This Klyn compatibility shortcut lets parsed element lists be consumed without an explicit cast. Non-element nodes return an empty string.

Parameters

- name Attribute qualified name.

Returns

Attribute value, or empty string when absent or unsupported.

Example

    id = node.getAttribute("id")