Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <HTML>
- <BODY>
- <H3> Test </H3>
- <FORM ACTION=test.pl METHOD=POST>
- <p>Please Enter Your Name: </p>
- <INPUT TYPE=TEXT NAME="name">
- <INPUT TYPE=SUBMIT>
- </FORM>
- </BODY>
- </HTML>
- use CGI;
- my $q = CGI->new;
- my $m = $q-> param("name");
- print "<html>";
- print "<body>";
- print "<head><title>form test</title>";
- print "</head>";
- print "<body>";
- print "<form method=POST action=test.pl>";
- print "<p>First value: </p> <input type = text name = fst>";
- print "<p>Second value: </p> <input type = text name = scd>";
- print "<input type = submit>";
- print "</form>";
- my $fname = $q->param("fst");
- my $fname2 = $q->param("scd");
- my $tot = $fname+$fname2;
- print "<h2> hi $m your total value is: $tot</h2>";
- print "</body>";
- print "</html>";
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement