This shouldn't be a problem, because that's the way to add non-ASCII
characters to XML documents. A proper XML parser should handle it...

// Magnus Holm (from my phone)

On Friday, June 18, 2010, Raimon Fernandez <co...@montx.com> wrote:
> Hi again,
>
> I know this is more related to builder than to camping, but not sure where to 
> ask for it ...
>
> :-)
>
>
> My app receives .xml file from some different sources, and all of them, 
> except the camping one, are formatted like this:
>
>
> <?xml version="1.0" encoding="UTF-8"?>
> <person>
>   <name>Jim Fernández</name>
>   <phone>555-1234</phone>
> </person>
>
>
> but camping is formatting like this:
>
> <?xml version="1.0" encoding="UTF-8"?>
> <person>
>   <name>Jim Fern&#225;ndez</name>
>   <phone>555-1234</phone>
> </person>
>
>
> The main difference is the encoding for some chars:
>
> á => &#225;
>
> I can't find in builder how to write values without escaping them ...
>
> thanks,
>
> r.
>
> On 17jun, 2010, at 21:04 , Magnus Holm wrote:
>
>> And if you want this XML:
>>
>> <?xml version="1.0" encoding="UTF-8"?>
>> <posts>
>>  <post>
>>    <title>Hiya</title>
>>    <content>Hey</content>
>>  </post>
>> </posts>
>>
>> You have this view:
>>
>> module App::Views
>>  def posts(xml)
>>    xml.posts do
>>     �...@posts.each do |post|
>>        xml.post do
>>          xml.title(post.title)
>>          xml.content(post.content)
>>        end
>>      end
>>    end
>>  end
>> end
>
>
> _______________________________________________
> Camping-list mailing list
> Camping-list@rubyforge.org
> http://rubyforge.org/mailman/listinfo/camping-list
>

-- 
// Magnus Holm
_______________________________________________
Camping-list mailing list
Camping-list@rubyforge.org
http://rubyforge.org/mailman/listinfo/camping-list

Reply via email to