Does anybody know how to generate a PDF/A document...
# cfml-general
g
Does anybody know how to generate a PDF/A document or convert an existing PDF (using Lucee)?
e
i just did a bunch of PDF generation work using CFDOCUMENT to convert HTML to PDF and it worked pretty good (using the more recent Flying Saucer engine), any specific questions? (i haven't done PDF conversion)
a
We've had some joy with using Playwright to convert HTML to PDF. You get great looking PDFs that support latest browser CSS etc, but you are limited in number of pages before it can't handle it.
g
PDF/A is a specific format which can not be generated by using cfdocument afaik
the background of this question is that we need to embed xml into pdf and the lib requires PDF/A as input
e
ah, gotcha, sorry missed the /A part
g
there is a java lib from Spire which actually doesn't generate a valid PDF/A
I think one of the issues is that Lucee generates PDF 1.4 which is a pretty old standard
a
Is this for XFA forms? You'll need PDF/A-2 for that I think.
g
It is a EU standard for electronic invoices which will become mandatory next year (https://www.mustangproject.org/)
e
does Adobe Coldfusion support it? If so maybe worth to have 1 paid instance to generate these
a
That library says "Converts any PDF to PDF/A-3" under "Mustang Server"
e
g
maybe I'm missing some but I could not use normal pdf as input (but I used the java impl)
we just removed all jasper dependencies, it's such a buggy lib
e
we used Jasper as replacement for CF Report Builder when switched from Adobe to Lucee
g
yes, we did for a while as well
e
lol - ya it has its moments 😉
a
Looks like you need the run the server to do it https://www.mustangproject.org/server/
g
thanks, I will check that
😠
m
PDF/A is supported in Adobe ColdFusion 2023+ only, using HTMLtoPDF https://helpx.adobe.com/coldfusion/cfml-reference/coldfusion-tags/tags-g-h/cfhtmltopdf.html We support PDF/A-1a or PDF/A-3a conformant files, as well as other PDF/A subformats.
g
Good to know, I will check that as well
👍 1
d
g
Wow, that‘s pretty cool, will try