#!/usr/bin/perl -T use strict; use warnings; use CGI qw(:standard); use CGI::Carp qw(warningsToBrowser fatalsToBrowser); my $cgi = new CGI; print $cgi->header(); print $cgi->start_html('My test text box'); print $cgi->startform; open my $FHIN, '<', "./test.file" || die "$!"; my @fhin = <$FHIN>; print $cgi->textarea( -name=>'TEXT_AREA', -default=>"@fhin"); print ""; print $cgi->end_html(); #### Content-Type: text/html; charset=ISO-8859-1 My test text box
#### My test text box #### this is a test file this is line two three 4 foo bar six