« Return to Thread: PDF upload problems (prob OT)?

Re: PDF upload problems (prob OT)?

by Joel Bernstein :: Rate this Message:

Reply to Author | View in Thread



2008/11/8 Dermot <paikkos@...>
2008/11/7 Dr. Jennifer Nussbaum <bg271828@...>:
> Anyone willing to help me on this? :-) Im only missing four bytes, somewhere.... Or adding them rather.
>
> Jen.

I can't test this from where I am writing but as Adeola says.

Open a temporary FH, binmode it, pour the content in. Then under MP2 you would

$r->sendfile($tmpfh);

content_type is 'application/pdf'

I guess the Cat alternative would be

$res->write( $tmpfh );

but you'd want to check that :)

I'd use $c->response->body( $filehandle ) to achieve this. I'm not sure what you're expecting ->write() to do there.

/joel

_______________________________________________
List: Catalyst@...
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/catalyst@.../
Dev site: http://dev.catalyst.perl.org/

 « Return to Thread: PDF upload problems (prob OT)?