Closed Omnia89 closed 6 years ago
Hi, try to use an absolute path for the image, the request host is correct?
Yes, the request host return the correct url.
I've tried those things:
Here i had the doubt that my file had something wrong, so I recreated the logo in .gif and:
Assets.versioned
and Assets.at
: not workingSo I ended making a little function that recreates the absolute url for the assets that I'm gonna use in the pdf.
Thanks for the tip, was the only thing I didn't tested!
Hello, i'm having some problems rendering a logo in a pdf.
In the scala template I've tried to load it both with
@routes.Assets.at()
and@routes.Assets.versioned()
. If I render normally the template, the image shows up, when I usereturn pdfGenerator.ok(PDFList.render(courseSession), request().host());
, no image. The image is a simple .png file.I'm using Play Framework 2.5 and play2-pdf 1.6.0 version (firstly tried with 1.7, but didn't worked)