http://www.perlmonks.org?node_id=131359


in reply to Any Examples on how to send via email a reply to my HTML form:

First of all, use CGI.pm (or Apache::Request) rather than parsing form data yourself.

Anyway, have separate names for the different operations (one operation is "send email", the other is "don't send email"). Maybe they are the names for submit buttons. Then, you check which name is present in the form data.

if ($form_name eq 'send email') { show_send_email_page(); } else { show_no_email_page(); }