JackHammer has asked for the wisdom of the Perl Monks concerning the following question:
The above prints out a very distorted image, any help would be appreciated!open(INFILE, "$filename"); binmode(INFILE); sysread INFILE, $filedata, $filesize; close(INFILE); #unbuffer STDOUT and print the file to the user $| = 1; print "Content-Type: image/jpeg Content-Length: $filesize\n\n"; print $filedata;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: reading binary files in windows
by merlyn (Sage) on Oct 27, 2000 at 03:49 UTC | |
by JackHammer (Acolyte) on Oct 27, 2000 at 22:55 UTC | |
|
RE: reading binary files in windows
by extremely (Priest) on Oct 27, 2000 at 04:24 UTC | |
by Fastolfe (Vicar) on Oct 27, 2000 at 10:45 UTC | |
by JackHammer (Acolyte) on Oct 27, 2000 at 22:54 UTC | |
by Fastolfe (Vicar) on Oct 28, 2000 at 01:40 UTC | |
by merlyn (Sage) on Oct 27, 2000 at 07:55 UTC |