From: Jim Weirich Date: 2006-03-23T14:13:39+09:00 Subject: Re: XmlStruct-1.0.0 released zdennis wrote: > It seems like the following would be more approriate, although it would > be more typing: > > xml.MyTag :xmlns+."..." { |xml| > xml.ATag "2.0" > xml.BTag { |btag| > btag.CTag { |ctag| > ctag.DTAG { |dtag| ....etc.... } > } > } > } > > This way I can easily visually tell that what the hiearchy looks like in > my xml document w/o having to count tabs or curly braces. If you really want to, that style works fine with XML builder too. require 'builder/xmlmarkup' xml = Builder::XmlMarkup.new(:indent=>2) xml.MyTag { |xml| xml.ATag "2.0" xml.BTag { |btag| btag.CTag { |ctag| ctag.DTAG { |dtag| } } } } puts xml.target! Produces: 2.0 -- -- Jim Weirich -- Posted via http://www.ruby-forum.com/.