I was going to mention that the PDF::API2 module uses the saveas method to set your file name. But then I noticed that you mention "browser". So I suspect that you're making a web app, in which case you're probably just not setting up the headers correctly in your response.
...roboticus
| [reply] [d/l] |
| [reply] |
Right. I tried:
print CGI::header( -type => 'application/pdf', -Content_disposition => 'inline;filename=\"myfilename.pdf\"')
but that did not work either. Nor did "-Content-disposition" with a hyphen instead of an underscore.
Still perplexed.
| [reply] |
While the header name may be Content_Disposition the parameter seems to be -content_disposition, at least as shown in the thread I refered to.
| [reply] |
Yes, I am writing the PDF to the browser. Here is how I am setting the header using CGI:
print CGI::header( -type => 'application/pdf',
-disposition => 'inline;filename=\"myfilename.pdf\"');
And here is how I set the "info" using PDF::API2:
%h = $pdf->info( 'Author' => "$username",
'Title' => "$ListTitle Donation Receipt $receiptno",
'CreationDate' => "D:$pdfyear$pdfmon$pdfday$pdfhour$pdfmin$pdfsec",
'Producer' => 'List Manager');
I am still no further ahead with this problem.
| [reply] |
Why are you inventing a header (Disposition)?
| [reply] |
After my post I saw that refs on the net to the usage of "-disposition" are wrong. But I also tried "-Content_disposition" and that did not work either.
Still perplexed.
| [reply] |