HTML sequences < and > breaking the output

Dear Aspose Support,
I’m experimenting an issue with very basic HTML handling.
Consider this source HTML:

<p>teste <strong>email</strong> &lt;name@domain.com&gt;</p> <p>test &lt;ciao&gt;</p>

If this string is loaded into an HTMLDocument and than saved back to HTML, the document becomes:

<head></head><body><p>teste <strong>email</strong> <name@domain.com></p> <p>test <ciao></p> </body>

Now if you try open such HMTL document into a browser, you see that, starting from the first & lt ;
, no content is rendered (basically & lt; is rendered as ‘<’ and HTML parsing breaks).
Anything I do with this HTML (e.g. inserting the snippet inside a DOCX) is of course broken in the same way.

Is there a way to properly handle/preserve & lt; and & gt; sequences?

Please find attached a simplified example.
Using Aspose HTML 22.7
EmbeddedHtmlSnippetTest.zip (563 Bytes)

Thanks in advance for your attention,
Kind Regards
FV

@fabrizio.vaglia

Could you please also share the generated HTML document in .zip format that you obtained at your end? We will further proceed to assist you accordingly.

Hello,
here it is the attachment: fromHtmlToHtml.zip (218 Bytes)

This was generated via the test case attached in the opening post.

Thanks for the attention
Kindest Regards
F

@fabrizio.vaglia

An investigation ticket as below has been logged in our issue tracking system to further analyze this scenario.

Issue ID(s): HTMLJAVA-1441

We will look into its details and keep you posted with the status of its correction. Please be patient and spare us some time.

We are sorry for the inconvenience.