programming-examples/perl/CGI/Generate the HTML form.pl

15 lines
349 B
Perl
Raw Normal View History

2019-11-15 12:59:38 +01:00
#!/usr/bin/perl
use CGI::Pretty qw(:all);
use strict;
print header();
print generate_form();
print end_html();
sub generate_form {
return start_form,
h1("Please enter your name:"),
p("Last name", textfield('last')),
p("First name", textfield('first')),
p(submit),
end_form;
}