PDF Writing without Cached File

I’m researching generating PDF files via RoR. I see there are packages
available to do this. One such package is the PDF-Writer. The examples
I saw for this package save the PDF to a file. Is there a way I can
output the PDF on-the-fly to the browser rather than having a temporary
PDF file?

I just can’t have these files laying around since they contain sensitive
information. I thought about just generating the PDF file and naming it
the session ID or something that’s not easily guessable, but I’d rather
just generate it in memory and dump it to the browser if possible.

On 5/24/06, The B. [email protected] wrote:

I’m researching generating PDF files via RoR. I see there are packages
available to do this. One such package is the PDF-Writer. The examples
I saw for this package save the PDF to a file. Is there a way I can
output the PDF on-the-fly to the browser rather than having a temporary
PDF file?

I just can’t have these files laying around since they contain sensitive
information. I thought about just generating the PDF file and naming it
the session ID or something that’s not easily guessable, but I’d rather
just generate it in memory and dump it to the browser if possible.

I suggest you read my article at Ruby Code & Style, “Creating
Printable Documents with Ruby”
(artima - Creating Printable Documents with Ruby). It addresses
this.

-austin

I suggest you read my article at Ruby Code & Style, “Creating
Printable Documents with Ruby”
(artima - Creating Printable Documents with Ruby). It addresses
this.

Thanks, I’ll definitely give this a read tomorrow morning when I get to
work!