Link Search Menu Expand Document

XmlElement.GetAttributeNode Method

Explanation Get the Attr node by specifying the attribute name .
Not supported in Mobile, AI
Call format var attr = elm.GetAttributeNode( name )
Return value XmlAttr object
Returns null if not found .
Arguments String name Attr node attribute name
Exception None
Example of use
    var domimpl = new XmlDOMImplementation;
    var res = session.Get("/test/sample.xml");
    var xmldoc = domimpl.Load(res);
    var elm = xmldoc.DocumentElement;
    var attr = elm.GetAttributeNode("width");
    print(attr.Value, "\n");
    
Related item XmlAttr class
SetAttributeNode, RemoveAttributeNode, HasAttribute, GetAttribute, GetAttributeNS, GetAttributeNodeNS method