* be careful. libxml represents the text value of an attr or ns node as a text node child of the attr or ns node. That does not match the XPath data model, where only root and element nodes can have children.