Add simple echo CGI script.
[newgopher.git] / public_gopher / echo.pl
blob55dca107eb10e1eed38afb7c93ad08c9f45f6263
1 #!/usr/bin/perl
3 $buffer = "Your SELECTOR is `" . $ENV{'GOPHER_SELECTOR'} . "'\n";
4 $buffer .= "You have sent ".$ENV{'CONTENT_SIZE'} . " bytes " .
5 "of content type `".$ENV{'CONTENT_TYPE'}. "' !\n";
7 $mimetype = 'text/plain';
9 $size = length $buffer;
10 print $size."\t".$mimetype."\r\n";
11 print $buffer;