in reply to Perl code doesn't echo form data
G'day nrabus,
Welcome to the Monastery.
From your description, it sounds like the problem lies with you web server configuration. I don't know what you're using but I'll take a guess at Apache. You need to specify in your configuration file — possibly named httpd.conf — that the cgi-bin directory has Perl code which the web server should execute. I can't tell you exactly what the configuration code would be; however, it might look something like:
<Directory "/cgi-bin"> SetHandler cgi-script Options +ExecCGI </Directory>
There's quite possibly other directives you'll need. I'm not really comfortable guessing any further.
If it is Apache, the default httpd.conf provides some clues. Get details from "Apache HTTP Server Version 2.4 Documentation"; although, you may need a different version. See the "Directive Index" for links to the documentation for individual directives.
I only briefly looked at your code. You generally seem to be on the right track. You've got a semicolon where you probably should have a comma after the "Last name:" part; alternatively, add another print after it (i.e. just before the "Gender:" part).
You also might like to consult the "CGI" and "CGI::HTML::Functions" documentation.
— Ken
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Perl code doesn't echo form data
by tobyink (Canon) on Mar 24, 2020 at 09:25 UTC | |
by nrabus (Initiate) on Mar 25, 2020 at 00:14 UTC | |
|
Re^2: Perl code doesn't echo form data
by nrabus (Initiate) on Mar 24, 2020 at 19:43 UTC | |
by kcott (Archbishop) on Mar 24, 2020 at 20:39 UTC | |
by nrabus (Initiate) on Mar 25, 2020 at 01:15 UTC |