Forum Feature requests

More control over embedded attachments

Worker
I have used both the --attach command-line parameter and the javascript PDF.attachFile function to embed attachments in a PDF. That works great. The attachment can even be a URL, and fetching that URL even uses the --cookiejar, which is fantastic.

First, I wish there was a way to control the attachment file name. Today if I attach "http://example.com/get_file.cgi?id=123", the file name shows up in the Attachments panel as "get_file.cgi_id=123". It would be better if Prince read the fetched file's name from the Content-Disposition header, but I could also be happy with a new parameter for PDF.attachFile to control the file name.

Second, I wish we could add file attachment annotations inside the PDF so that attachments could be accessed from inside the PDF rather than only through the PDF viewer's Attachments panel.
mikeday
We will add an optional third argument to PDF.attachFile to specify the filename.

We can investigate the attachment annotation, perhaps it can be done by adding a new link type.
Worker
Awesome. Thank you!
abaker87
Mike,

Would this be inline with adding a way to link to a specific attachment (or further a specific page in an attachment)?

Andrew
mikeday
Maybe! We will need to investigate.
abaker87
:D
mikeday
The latest build now includes the optional third argument to PDF.attachFile to specify the filename.