Export to single HTML with embedded images using Jasper Report

前端 未结 5 858
天命终不由人
天命终不由人 2021-01-04 20:32

Can Jasper Report export to single HTML with embedded images?

I have output of jasper reports as single Excel file, PDF, RTF. But multiplay HTML files. It trouble fo

5条回答
  •  执念已碎
    2021-01-04 21:18

    I don't think that jasper reports has built in support for this, so you'd have to roll out your own implementation. You can use this technique to embed them images.

    
    

    So first you'd use java's xml parser to find all the image tags in the html http://www.mkyong.com/tutorials/java-xml-tutorials/. Then you'd read all the files, convert them to base64 string http://www.xinotes.org/notes/note/736/ and replace the img's src with the above format.

提交回复
热议问题