#!/usr/bin/perl
#########
#
# in class demo of a CGI script.
#
#######

use CGI qw(:standard);
use CGI::Carp qw(fatalsToBrowser);

my $word = param('George');
my $htmlAboutWord = "";
if ($word){
  $htmlAboutWord = "You typed '$word'.";
}

print "Content-type: text/html\n\n";

print qq{
 <html>
 <head><title>Hi.</title></head>
 <body>
   SAMPLE HTML FORM
   <hr>
   <form method="get" action="inclass.cgi">
   <input type="text" name="George">
   <input type="submit">
   </form>

 $htmlAboutWord

 </body>
 </html>
};
