Sorry that I'm not good enough in expressing the idea in English. I do program enough in Perl and this is my testgif.pl script. Maybe this example is better.
=================================
in the html code I'm using is (ofcourse with the html-symbols around it:
img src="../cgi-bin/testgif.pl?werkplek.gif"
==================================
The Perl script is:
#!/bin/perl5.005_03 -w
use strict;
use CGI qw(:all);
my ($buffer);
if (open (INHOUD, "../docs/gemjcw/doc/sb/werkplek.gif")) {
binmode INHOUD;
print << "EOT1";
Content-Type: application/msword; filename="werkplek.gif"
EOT1
while (read(INHOUD, $buffer, 4096)) {
print $buffer;
}
close (INHOUD);
exit;
==========================
And the result is "
Thu Jan 12 14:37:10 2006 error client 82.168.213.19 malformed header from script. Bad header=GIF89a(: /www/cust/y/3/3/5/33515/cgi-bin/testgif.pl"
==================================