From: Phlip Date: 2009-02-14T02:38:38+09:00 Subject: Re: Xpath Alberto Alberto wrote: > Xpath: //terzo[@id='3'] > > Output: > /primo/secondo/terzo[id='3'] You meant / not //. Try this: REXML::XPath(doc, "//terzo[@id='3']").xpath That's off the top of my head; advise me if it didn't work! I know there's a .xpath or .path in there somewhere... (And I suspect Nokogiri provides a better XML ride!) -- Phlip