FormMail CGI Script for
Web-based Forms
What is FormMail?
With the CGI script FormMail, developed by Matt's Script Archive, you
can create a generic web form and have information that people enter
on the form sent to the e-mail address you specify.
What happened to the "mail-form" script?
The mail-form script was retired on May 22, 2002. You are encouraged
to use FormMail, which offers more options for form fields and for formatting
e-mailed data.
Web forms require 2 components:
- HTML source code describing the layout of the form. Design your form
using a web editing program such as FrontPage, Dreamweaver, GoLive!
Specify the form action, define any hidden fields, or fields, checkboxes,
radiobuttons for user input.
- An application or script to process the form data and send it in an
e-mail message. This application must reside on the server or be a client-side
script. In this case, FormMail has been installed and configured on
the central server.
The action of your form must point towards this script.
<form action="http://www.uiowa.edu/cgi-bin/formmail.pl"
method=POST">
You can copy/paste the HTML from a sample
form into a new web document and then modify it.
What fields are necessary?
There is only one form field that you must have in your form, for
FormMail to work correctly. This is the recipient field.
Field: recipient
Description: This form field allows you to specify to whom you
wish for your form results will be mailed. Most likely you will want
to configure this option as a hidden form field with a value equal to
that of your e-mail address.
Effective May 22, 2002, this field is limited to e-mail addresses
that end in "uiowa.edu". A maximum of 5 recipient addresses
may be specified.
Syntax: <input type=hidden name="recipient" value="email@uiowa.edu">
What's new?
Version 1.9 adds the ability to allow the form results E-mail to display
the remote hostname, IP address and referring URL of the submitter of
the form. This information is appended to the end of the form results
E-mail like this:
REMOTE_HOST: fire.its.uiowa.edu
REMOTE_ADDR: 128.255.69.58
HTTP_REFERER: http://www.uiowa.edu/~sitename/
Note: The display of this host information will occur by default, however,
if you wish to disable this additional information to maintain the anonymity
of form responders you can include the following hidden tag within the
form:
Syntax: <input type="hidden" name="env_report"
value="">
What are the optional fields?
There are many optional fields that will allow you customize the way
the form is processed. For example:
- You can specify the subject of the e-mail message you will receive
- You can allow the user to input the e-mail address that will show
up in the "From" field of the e-mail you receive.
- You can specify fields that the user must fill out before the form
can be submitted
What are the limitations of FormMail?
- Forms submitted from a client computer that resides behind a firewall
may not reach the recipient as the firewall will likely block the passing
of the required referer information such as the submitters IP address.
For a complete list see the FormMail
ReadMe document.
If you have questions about using this form, please contact:
the ITS Help Desk, 15
LC, its-helpdesk@uiowa.edu,
384-HELP.
|