#!/usr/local/bin/perl #HiWally in Perl #Modified for cgi #import the cgi library routines require "cgi-lib.pl"; #call the routine to specify CGI output print &PrintHeader; print &HtmlTop("Hi Wally"); $userName = ""; #string for user's name # get userName from form &ReadParse(*input); $userName = $input{"txtUserName"}; print "

$userName

\n"; if ($userName =~ m/wally/i){ print(""); print("You PIG!!!
\n"); print("
\n"); } else { if ( $userName =~ m/quit/i){ print(""); print ("Goodbye!
\n"); print("
\n"); } else { print(""); print ("Do I know you $userName?
\n"); print("
\n"); } #end quit if } # end wally if print &HtmlBot;