From: Mark Probert Date: 2003-01-09T05:02:38+09:00 Subject: REXML basic question Hi. I've just started to play with REXML ... $ cat x.xml
Foo text goes here
Bar text goes here
How do I iterate over the sections? I have: @doc = Document.new File.new( "x.xml" ) @doc.elements.each("tutorial/doc") { |elem| section = elem.attributes["name"] } Gives me "S1" and "S2". How do I iterate over these sections to get and <body>? I am missing something simple... -mark.