#!/usr/bin/perl
use strict;
use warnings;
use CGI qw(:all);
my $q = CGI->new;
print $q->header();
print $q->start_html();
print $q->img({src => 'image.gif'});
print $q->end_html();
####
#!/usr/bin/perl
use strict;
use warnings;
use CGI qw(:all);
my $q = CGI->new;
print $q->header(-type => 'image/gif');
open(my $F, '<', '1.gif') || die "can not open\n";
local $\ = undef;
print <$F>;
close($F);
##
##
#!/usr/bin/perl
use strict;
use warnings;
use CGI qw(:all);
my $q = CGI->new;
print $q->header();
print $q->start_html();
print $q->img({src => 'img.pl'});
print $q->end_html();