Form To Mail Instructions
... Have Form Responses Sent to Your Email Account! ...
Description:
FormToMail is a CGI program that Intersessions' web hosting accounts can use to have the responses to their forms sent to them by email. Using the instructions that follow you can easily create forms that:
Instructions:
Intersessions' FormToMail CGI program
can be added to any web page. Just add the form action command and the hidden
HTML tags as described below. The form action command activates the program and the
hidden tags allow you to control how it works. The form action command is placed at the
start of the form section of your document and defines the CGI program that will be used
to process your form. The hidden tags defined below and your form elements are entered
after the form action tag. At the end of your form - after all form elements and the
submit button be sure you have a closing form tag "</FORM>".
If you would like to see what these HTML tags look like in practice just pull up our 'web
hosting order form' and use the 'view source' option on your web browser. You'll see
exactly where the form action command was placed and how the hidden tags were placed.
Form Action Command:
You'll need to add this HTML line to your form for the CGI program to work. It becomes the
opening form tag:
<FORM METHOD="POST" ACTION="/cgi-bin/formtomail.pl" ENCTYPE="x-www-form-encoded">
<input type=hidden name="recipient" value="johndoe@intersessions.com">
Specifying the subject:
Here's where you can enter a few words to use for the subject of the email message. You
can omit this tag but if you're getting emails from a number of forms you may want use the
subject line to distinguish between them. If you don't use this tag the CGI program will
use "WWW Form Submission" as the message subject.
<input type=hidden name="subject" value="Your Subject">
Redirection:
Redirection sounds complicated. It works like this: After your user presses the submit
button and the information on the form is sent on its merry way one of two things can
happen. Either an acknowledgement page will appear or the user will be 'redirected' to
another page (e.g. your home page.) The default is to have the CGI program send an
acknowledgement page but if you would rather send the user to your home page or elsewhere
just add this hidden tag.
<input type=hidden name="redirect" value="http://www.you.com/index.html">
Requiring Values:
You can require that certain fields in your form to be filled in before the user can
successfully submit the form. Place all field names that you want to be mandatory into
this tag. If the required fields are not filled in, the user will be notified of what they
need to fill in, and provided with a link back to the form they just submitted.
For example, if you want to require that they fill in the email and phone fields in your
form, so that you can reach them once you have received the mail, add the following tag:
<input type=hidden name="required" value="eemail,phone">
Note: Due to a small bug in the program don't use 'email' as the name of a form field. Use
'eemail' or something else instead. Sorry.
Specifying the Order of Values:
Unless you use this tag FormtoMail will list the information from in random order. This
tag allows you to choose the order in which you want this information to appear. You can
choose to have the information sorted alphabetically or specify a set order in which you
want the fields to appear in your mail message. If you leave this tag out the order will
simply default to the order in which the browsers sends the information to the script
(which isn't always the exact same order they appeared in the form.) When sorting by a set
order of fields, you should include the phrase "order:" as the first part of
your value for the sort field, and then follow that with the field names you want to be
listed in the e-mail message, separated by commas.
To sort alphabetically:
<input type=hidden name="sort" value="alphabetic">
To sort by a set field order:
<input type=hidden name="sort" value="order:name1,name2,etc...">
Acknowledgement Page Title:
This tag allows you to specify the title and header that will appear on the
acknowledgement page if you do not specify a redirect URL. For example, if you wanted a
title of 'Feedback Form Results':
<input type=hidden name="title" value="Feedback Form Results">
Specifying the Return Link URL:
At the bottom of the acknowledgement page you can specify a link to a page you want the
user to go to next (e.g. your home page). This tag and the one that follows define the URL
of that link and title of the link appearing on the acknowledgement page. This field will
not be used if you have the redirect field set.
<input type=hidden name="return_link_url" value="http://www.you.com/main.html">
Specifying the Return Link Title:
This tag sets the title of the link that will appear on the acknowlegdement page for the
link to the page you specify with return_link_url. The two fields will be shown on the
resulting acknowledgement page in HTML code as:
<ul>
<li><a href="return_link_url">return_link_title</a>
</ul>
The return link title is specified as follows;
<input type=hidden name="return_link_title" value="Back to Main Page">
Setting the Background Image:
This tag allows you to specify a background image that will appear on the acknowledgement
page.
<input type=hidden name="background" value="http://www.you.com/image.gif">
Setting the Background Color:
This tag allows you to specify a background color for the acknowledgement page in much the
way you specify a background image. This field should not be set if the redirect tag is.
For a background color of White:
<input type=hidden name="bgcolor" value="#FFFFFF">
Setting the Text Color:
This tag works in the same way as background color, except that it will change the color
of your text on the acknowledgement page. Should not be defined if the redirect tag is.
For a text color of Black:
<input type=hidden name="text_color" value="#000000">
Setting the Link Color:
Changes the color of links on the acknowledgement page. Works in the same way as
text_color. Should not be defined if the redirect tag is.
For a link color of Red:
<input type=hidden name="link_color" value="#FF0000">
Setting the Visited Link Color:
Changes the color of visited links on the acknowledgement page. Works exactly the same as
link_color. Should not be set if the redirect tag is.
For a visited link color of Blue:
<input type=hidden name="vlink_color" value="#0000FF">
Setting the Active Link Color:
Changes the color of active links on the acknowledgement page. Works exactly the same as
link_color. Should not be set if the redirect tag is.
For a active link color of Blue:
<input type=hidden name="alink_color" value="#0000FF">
Intersesiones.com es una marca y dominio registrado por Intersessions Inc. y Estudio Nemo®
| Soporte
en español: Bv Oroño 679 - 5 Piso - 2000 - Rosario - Santa Fe - República Argentina Teléfono y Fax: +54 - 341 - 425-8356 Email: soporte@estudionemo.com |
English
support: Box 555, Tenafly, New Jersey 07670 201-569-1762 (Voice), 201-569-7898 (Fax) Email: support@intersessions.com |