0
votes

I have an xml document which contains embedded pdf documents in base64 format. I'm using xsl:fo to create a pdf view of the xml, however I have absolutely no idea how to display the embedded documents as part of the overall output using xsl. Could someone help here please. Apologies if this is a very simple question, however I'm brand new to XSL and cannot seem to find any example of this anywhere.

1
It is not a simple question. I think it is possible to do what you want, but not by using only standard XSLT and XSL-FO. Some additional processing logic is needed. Perhaps someone can help if you provide more details about your requirements, environment, toolchain etc. - mzjn

1 Answers

1
votes

PDF documents are vector images in some sense, and thus can be embedded into PDF output of an XSL FO rendering engine -- so far the first page only.

RenderX XEP accepts data: as URI schema for embedded images, so a base64 encoded PDF file placed as a string to fo:external-graphic/@src should work fine:

src="url('data:application/pdf;base64,encodedpdffilegoeshere...')"