You can insert a file attachment into a PDF document using a special tag pdf-attachment
. There are two
required attributes filename
used as a simple name of the file inside the PDF and href
which is a reference
to the file you wish to insert. You should use an appropriate filename with extension so that it will open using the associated application.
<pdf-attachment filename="data.xlsx" href="/Resources/Attachments/data.xlsx"/>
The file data.xlsx is attached inside this PDF here using the code above. We've used a little CSS to style
the <pdf-attachment> tag:
Clita invidunt veniam tempor est clita consetetur eirmod. Dolores ipsum no blandit ipsum clita ipsum sit sed est clita sed est. Ut kasd et lorem rebum sed ipsum erat nobis tempor dolores. Stet vel voluptua sed facilisis duo eros justo erat facilisis diam sed ipsum sed diam sed et. Vero amet dolore amet eirmod voluptua et.
Te sed iusto. Et dolores justo lorem et vero amet gubergren consetetur et ea et. Et kasd blandit iriure et at. Et nonummy et dolor duo erat sit sanctus diam. Dolores in dolor takimata justo dolore consequat sed duis ipsum vulputate est aliquyam vel sit ea. Sanctus takimata diam tation tempor erat duo duis sed amet duo magna. Vero sadipscing et eos et nonummy eirmod. Dolor lorem ut sit ipsum iusto. Molestie ex lorem est ipsum.