From: Florian Gilcher Date: 2012-01-20T05:55:40+09:00 Subject: Re: XmlMarkup gives 2 root elements On Jan 19, 2012, at 7:08 PM, Holm Dressler wrote: > Hi there, > > I try to check out what's the best way to create a small XML File (need > it for a bank transfer) > > Anyway: I try the following under the ruby console: > > require 'builder' > x = Builder::XmlMarkup.new > x.instruct! > test = x.Hello("World!", "type" => "global") > > What I receive in test is the following: > > > > World!" > > So how can I get rid of the element. I think this file is A > BIT against the W3C XML standard. > > Thanks for any advices, > > Holm Try it without irb. Standard IRB automatically calls "inspect" on the builder object after each line which adds the "inspect" element ;). Regards, Florian