RE: Delivering binary content from a Embperl application

2006-08-09 Thread Gerald Richter
Wednesday, August 09, 2006 7:03 PM > To: Gerald Richter > Cc: 'Frank Wesemann'; embperl@perl.apache.org > Subject: Re: Delivering binary content from a Embperl application > > Gerald Richter dijo [Mon, Aug 07, 2006 at 03:59:30PM +0200]: > > This might work with Apac

Re: Delivering binary content from a Embperl application

2006-08-09 Thread Frank Wesemann
This is what finally worked for me: binmode ( STDOUT ); my @blob = $image->ImageToBlob(); ( This means my $var = $file->getData() in your terms ) print $blob[0]; exit; I use it to manipulate Imagedata ( jpegs ) -- mit freundlichem Gruß Frank Wesemann Fotofinder GmbH US

Re: Delivering binary content from a Embperl application

2006-08-09 Thread Gunnar Wolf
Gerald Richter dijo [Mon, Aug 07, 2006 at 03:59:30PM +0200]: > This might work with Apache 1.3 by chance, but it will not with Apache 2.0, > because $image->write('-') writes to STDOUT which is never send to the > client, at least not by default. > > The best would be to do something like > > $im

RE: Delivering binary content from a Embperl application

2006-08-07 Thread Gerald Richter
> > Try putting the following before the write: > >tie *OUT, 'Embperl::Out'; >select(OUT); > This will redirect the Perl STDOUT to Embperl's output, but not the C one and I guess the output from ImageMagik is done by it's C code Gerald ** Virus checked by BB-5000 Mailfilter **

Re: Delivering binary content from a Embperl application

2006-08-07 Thread Torsten Luettgert
On Mon, 2006-08-07 at 11:20 +0200, Frank Wesemann wrote: > Torsten Luettgert schrieb: > > Don't know about Embperl object, but for me, it "just works". > > Here is some (reduced) code I use for delivering jpeg images: > > > Interesting enough this doesn't work ( it outputs nothing! ): > > > [- >

RE: Delivering binary content from a Embperl application

2006-08-07 Thread Gerald Richter
> > Torsten Luettgert schrieb: > > Don't know about Embperl object, but for me, it "just works". > > Here is some (reduced) code I use for delivering jpeg images: > > > Interesting enough this doesn't work ( it outputs nothing! ): > > > [- > ># some permission checking and obtaining $imgpath

Re: Delivering binary content from a Embperl application

2006-08-07 Thread Frank Wesemann
Torsten Luettgert schrieb: Don't know about Embperl object, but for me, it "just works". Here is some (reduced) code I use for delivering jpeg images: Interesting enough this doesn't work ( it outputs nothing! ): [- # some permission checking and obtaining $imgpath omitted if( -f $imgpa

Re: Delivering binary content from a Embperl application

2006-08-04 Thread Torsten Luettgert
On Wed, 2006-08-02 at 12:50 -0500, Gunnar Wolf wrote: > Ok, here goes the question: My applications have to deliver binary > content stored in a database or generated on the fly. How can I do > this from within my Embperl structure (I'm using the Embperl object > application), without having to del