Show Signature Field in Print Format PDF

Hi Everyone,

I tried attaching the Signature field to a print format using the html tag like the one below:

<img src = {{doc.signature}} height = "200px" width = "200px">

I can see the signature in the print preview and the Full Page HTML view.


But when I want to save the document as a PDF, the image turns into a blank square.

Anyone else having the same issue?

Thanks,

Hera

It may be that the pdf generation can not access the image path, or that the image has something that the pdf generator does not like as the type of transparency if it is a png for example. Try another image to see if it does the same.

HI @littlehera

would it not be

<img src="{{doc.signature}}" height="200px" width="200px"> 

so with quotation marks and no spaces - maybe that makes a difference rendering it to pdf?

please give your html view´s source code so I could investigate further
as Im still on version 7 hence I dont have signature field to try myself

if not it could actually be that wkhtmltopdf cannot handle base64 encoded data like the signature wich basically is base64

see here

https://github.com/wkhtmltopdf/wkhtmltopdf/issues/3591

1 Like

Managed to fix it by changing the src to /files/the_image_name . :smiley: Thanks all!

3 Likes