openhtmltopdf icon indicating copy to clipboard operation
openhtmltopdf copied to clipboard

Embed images to PDF without using HTML

Open anjanesh opened this issue 2 years ago • 1 comments

How do I add images to the PDF without using a link or base64 string ?

byte[] bytArr = oHelper.GetImageFromFirebase(imgUrl, false);

The reason why link is not available is because its not globally available - only on localhost.

No base64 string because the size becomes huge since there are about 100 images.

So I am looking for a way to add images in the middle of the HTML page like we can do in mPDF - $mpdf->Image();

anjanesh avatar Feb 09 '23 06:02 anjanesh

Hi @anjanesh, I think this can be handled with a custom uri resolver.

https://github.com/danfickle/openhtmltopdf/wiki/Integration-Guide#uri-resolver

schulm avatar Feb 09 '23 12:02 schulm