## use CGI qw(header); my $html = defined($ENV{'SERVER_SOFTWARE'}) ? header : ''; # More stuff gets added to $html before it prints to STDOUT