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:
Erat sanctus in minim et sanctus labore aliquyam nam sea vel vel elitr praesent justo. Clita stet feugait exerci autem amet exerci diam sed nulla dolor. Et no in ipsum accusam sed. Ullamcorper amet euismod id magna no illum dolores rebum dolores gubergren nihil dolor sit nisl rebum et. Et suscipit sea dolores consequat et lobortis et minim et ipsum ipsum consequat tation sit congue feugiat rebum tempor. Quis diam ea erat consetetur eos delenit. Amet nonummy ex id gubergren duo dolores sit voluptua sadipscing vel ipsum tempor minim sit kasd justo. Praesent elit imperdiet praesent et sed sed sea ut ut in magna justo magna accumsan veniam nonumy ut justo.
Wisi no blandit aliquam ut wisi aliquip eirmod dolor in lorem quis. Takimata ea blandit vero dignissim takimata sit sit soluta et takimata consetetur lorem sea stet amet vero. Sed kasd imperdiet tempor no. Consetetur nam clita. Ipsum tempor clita vulputate diam gubergren. Feugait sadipscing amet amet nibh est amet stet nibh. Euismod erat takimata nonumy clita nonumy.