http://qs321.pair.com?node_id=793576


in reply to Re: XML data reading/output
in thread XML data reading/output

I got better results with
$doc->findnodes( '//descriptors[@type="CTC"]/descriptor/mainterm/text( +)'

Replies are listed 'Best First'.
Re^3: XML data reading/output
by ikegami (Patriarch) on Sep 04, 2009 at 20:27 UTC
    arg, yeah, dumb mistakes. But not the third one. Contrary to your claims, the OP wants the whole element ('<mainterm weight="a">G</mainterm>'), not just the text ('G').