atom_Feed do |Feed| @stories.each do |story| Feed.entry story do |entry| entry.title story.title entry.content "<b>foo</b>" end end end
将产生文字:
<b>foo</b>
而不是:foo
有没有办法指示XML构建器不转义XML?
entry.content "<b>foo</b>",:type => "html"
虽然将它包装在CDATA中会阻止它工作.