Home > Back-end >  Itext method to HTML to PDF, an error
Itext method to HTML to PDF, an error

Time:12-02

Com. Itextpdf. Tool. XML. Exceptions. RuntimeWorkerException: Invalid nested tag head found, expected closing tag meta.
At com. Itextpdf. Tool. XML. XMLWorker. Same (135) XMLWorker. Java:
At com. Itextpdf. Tool. XML. Parser. XMLParser. Same (XMLParser. Java: 397)
At com. Itextpdf. Tool. XML. Parser. State. ClosingTagState. Process (ClosingTagState. Java: 71)
At com. Itextpdf. Tool. XML. Parser. XMLParser. ParseWithReader (XMLParser. Java: 237)
At com. Itextpdf. Tool. XML. Parser. XMLParser. Parse (XMLParser. Java: 215)
At com. Itextpdf. Tool. XML. Parser. XMLParser. Parse (XMLParser. Java: 176)
At com. Itextpdf. Tool. XML. XMLWorkerHelper. ParseXHtml (XMLWorkerHelper. Java: 222)
At com. Itextpdf. Tool. XML. XMLWorkerHelper. ParseXHtml (XMLWorkerHelper. Java: 230)
At com. Shineyue. Util. Test. The main (28) Test. Java:

CodePudding user response:

Try to use free spire. PDF for Java to transform, refer to https://www.e-iceblue.cn/pdf_java_conversion/java-convert-html-to-pdf.html

CodePudding user response:

Check whether there is HTML meta closing tag

CodePudding user response:

refer to the second floor big hidden in the temple of the reply:
closed check HTML meta tag
third-party returns HTML page, abandoned, changed a way of implementation requirements

CodePudding user response:

reference 1st floor Jazz_z response:
spire. Try to use free PDF for Java to transform, refer to https://www.e-iceblue.cn/pdf_java_conversion/java-convert-html-to-pdf.html
thank you, gave up this way, in a way of implementation requirements
  • Related