From: Premshree Pillai Date: 2005-06-06T23:53:05+09:00 Subject: Re: rexml child nodes On 6/6/05, Charles L. Snyder wrote: > But, I can't figure out A) how to get at the vaules in the nodes - > the code below just gives me results of the form "6" > > require "rexml/document" > include REXML > doc = Document.new File.new("myQuiz.xml") > quiz=[] > doc.elements.each("QUIZ/QUESTION/CHOICE") { |element| quiz.push element} > puts quiz doc.elements.each("QUIZ/QUESTION/CHOICE") { |element| p element.text } -- Premshree Pillai http://www.livejournal.com/users/premshree/