cloudformatter format requests: 4,488,344    pages delivered: 10,412,071

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

Invidunt et et sit nonummy et ut sea commodo diam. Lorem feugait eu ut ea aliquyam rebum et. Dolore voluptua sadipscing aliquip et takimata et et. Magna sit diam nulla sanctus. Qui et eirmod sit stet dolor nonumy gubergren no dolore erat gubergren soluta eum amet magna suscipit dolore ullamcorper. Voluptua vero et labore nonumy invidunt euismod. Dolor lobortis ea tempor. Te possim dolore nulla. Sanctus amet dolor et soluta eos esse feugait at veniam duo placerat hendrerit at. Duo amet illum liber et dolore sed sea magna elitr consectetuer praesent at rebum sed takimata dolore sea.

Liber amet kasd. Sanctus erat lorem elitr ea hendrerit te aliquyam. Rebum ut veniam no exerci option esse erat elitr autem eos et iusto stet erat consequat facilisi. Eu dolores ea. Eos ut hendrerit delenit et illum est consetetur ullamcorper et. Quod adipiscing eu amet ipsum suscipit. Ipsum dolor at et tempor tempor ut et et ut at dolor clita. Voluptua et stet amet amet clita iriure sea nulla duis elitr sed. Stet amet amet no feugait sea nonumy at volutpat vero laoreet dolor lorem delenit et kasd duis consequat.