Page 1 of 1

Issue with html tags value with no quotes ((XHTMLImporterImp

PostPosted: Thu Nov 03, 2016 4:43 am
by james liu
Hello I am new to docx4j, I have a issue to import html using XHTMLImporterImpl.

The html ia a standard html, and there is no quote with the tag value, for example:
<meta http-equiv=Content-Type content="text/html; charset=windows-1252"/>

And I always got the error: "Open quote is expected for attribute "http-equiv" associated with an element type "meta"."

If I added the quote manually, like below: <meta http-equiv="Content-Type" content="text/html; charset=windows-1252"/>, then everything is working.

But I have many html files, and I could not manually added quotes around tag values. could you please help me fix this issue. Thanks

I am using Docxfj-ImportXHTML-3.3.1

Re: Issue with html tags value with no quotes ((XHTMLImporte

PostPosted: Thu Nov 03, 2016 7:23 am
by jason
You need to input XHTML ie well formed XML.

See http://stackoverflow.com/questions/6113 ... wser-would for some options