Comment 5 for bug 984575

Revision history for this message
Robert Lyon (robertl-9) wrote :

According to the documentation here: http://www.leapspecs.org/2A/literals#content_or_description

We should not be trying to import <content></content> as HTML (all escaped) but rather as XHTML (not escaped)

eg, instead of this:
<content type="html">&lt;p&gt;&amp;nbsp;&lt;/p&gt; &lt;p&gt;a paragraph&lt;/p&gt; &lt;p&gt;&amp;nbsp;&lt;/p&gt</content>

it should be more like this:

<content type="xhtml">
<div xmlns="http://www.w3.org/1999/xhtml">
<p> </p> <p>a paragrapgh</p> <p> </p>
</div>
</content>

where the containing <div> gets stripped on import

So on import should we take the contents of <content type="html"> unescape it, then run it thru html tidy and import it as xhtml?