programming-examples/perl/CGI/Data-Entry Forms in Web Pages.pl
2019-11-15 12:59:38 +01:00

29 lines
664 B
Perl

<html>
<body>
<FORM METHOD="POST" ACTION="index.cgi">
<H2>Customer Order Tracking</H2>
Enter order number:
<INPUT NAME="orderno">
<p>
<INPUT TYPE="submit" VALUE="Look up">
</FORM>
</body>
</html>
#!/usr/bin/perl -w
# CGI script using CGI.pm module.
use CGI;
$form = CGI->new();
$orderno = $form->param('orderno');
print $form->header();
print $form->start_html(-title=>'Customer Order Tracking',-BGCOLOR=>'white');
print "<h1>Your Order Number</h1>\n";
print "Your order number was: $orderno.\n";
print "<p>\n"; # Paragraph
# End HTML form.
print $form->end_html();