cloudformatter format requests: 5,032,479    pages delivered: 11,252,720

PDF File Attachments

xportability LLC

PDF File Attachments


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:

Notice: If you are using some browser-based viewer like Chrome, you probably will not see attachments. It is because that product does not support them. Download the PDF locally and use a PDF viewer that supports them.

Sample Heading

Euismod zzril kasd et lorem labore. Sed eos lobortis esse ut vero. Diam duo sea sanctus voluptua duo kasd takimata sed est labore dolor dignissim rebum nibh amet invidunt hendrerit. Sadipscing takimata erat exerci takimata odio kasd. Invidunt euismod ipsum minim kasd sed sed sadipscing autem ipsum labore enim suscipit wisi est eirmod diam. Ipsum lorem dolores aliquyam dolore est magna eirmod zzril sed sea vero sit lorem dolor vero. Quis sea at et lorem consequat tempor sit dolor nobis vero eos sed. Te sanctus et qui duo voluptua dolore erat ipsum sit eos. Sit et sadipscing. Ea nonumy molestie ut ut facilisis dolore consetetur ipsum sit dolor. Ut dolor takimata et tempor dignissim adipiscing justo laoreet vel vero dolore ipsum dolores.

Duo et consequat est odio vel dolor invidunt. In consetetur aliquyam at amet consequat amet veniam. Sit feugiat sed lobortis sit no amet et amet nulla clita ipsum rebum. Labore sed at exerci labore at duis diam consequat accusam sadipscing amet voluptua qui. Sed ipsum autem praesent ipsum accusam dolores no. Voluptua et sanctus erat duis sanctus. Tempor dolor aliquam sit et.