Basics of use
Sending a Thank You Page
Secure Server
Having Us Set Up a Form for You

For a simpler approach, check out the control panel options.

To modify an existing HTML form to work with the script cgiemail you will need to use the following form action within your HTML code:

<form method="post" action="/cgibin/cgiemail/mailform.txt">

Please Note: If you are a FrontPage user with the FrontPage 2000 extensions installed on your site, you will use this path instead:

<form method="post" action="/cgibin/cgiemail/mailform.txt">

(The difference is that you are using "cgibin" instead of "cgi-bin".)

This code calls the preinstalled script cgiemail which is in the server's cgi-bin directory once the web page visitor clicks the "submit" button. The script cgiemail in turn calls a text file (or template) called mailform.txt. The template defines the format by which the submitted form content is to be sent via e-mail.

Create the template in a basic text editor (such as MS Notepad, Ultra Edit, or other product). Always start it with the following two lines:

   To: username@yourbiz.com
   Subject: The Information Requested

Substitute the desired recipient e-mail address and subject above. If your form asks for the e-mail address of the visitor (be sure to name this field: e-mail), add this as the second line of the template:

From: [e-mail]

There can be no blank lines at the top of the file and no blank spaces at the beginning of these header lines.

Next, you will need to add ALL field names within the html form to the template in a form similar to the following:

   To: username@yourbiz.com
   From: [e-mail]
   Subject: Information Request

   Name            [realname]
   Address         [address]
   Phone           [telno]

As long as each form field name is contained within brackets ("[ ]") within the template, the e-mail should be sent successfully and contain all submitted data. We suggest using all lowercase field names within your html form and template.

If you want a specific web page to load when the e-mail is successfully sent, such as a thank you note, add the following code to your html form:

  • <input type="hidden" name="success" value="http://www.yourbiz.com/thanks.html">

Substitute the URL of the file you wish to load after form data is submitted. The field name in this case MUST be "success", but does not need to be added to the template.

  • For FrontPage users the path will be same:

<form method="post" action="/cgibin/cgiemail/mailform.txt">

<form method="post" action="https://wwwXXXX.securedweb.net/cgibin/cgiemail/<yourdomain>/mailform.txt">

where XXXX should be substituted with the number of your server. (Contact us for which server you are on.)

  • For Secured Server with Frontpage the path would be:

    <form method="post" action="https://wwwXXXX.securedweb.net/cgi- bin/cgiemail/<yourdomain>/wwwfp/mailform.txt">

    where XXXX should be substituted with the umber of your server. (Contact us for which server you are on.)

IMPORTANT POINTS:

  • There are only two parts to your e-mail forms, the form itself & the .txt template. The cgiemail.cgi program resides in our root system for you to use.
  • The servers are case sensitive. The cases on the html form and txt file MUST be identical in all forms. (RealName is not the same as realname.)
  • The .txt file can be named anything.txt and placed anywhere in your site as long as the path reflects its location (for example).

    <form method="post" action="/cgibin/cgiemail/mailform.txt">
    the mailform.txt file is in your root directory

    <form method="post" action="/cgibin/cgiemail/forms/mailform.txt">
    the mailform.txt file is in directory called forms

  • When using the secure server, make sure you are using the proper server number (i.e. www, www2, etc.).

Secure forms should have both

a)   The link to the form secure:
                      
<a href="https://wwwXXXX.securedweb.net/yourdomain/yoursubdirectory/order.htm">Secure Order Form</a>

b)   The link to the cgiemail program secure:

<form method="post" action="https://wwwXXXX.securedweb.net/cgibin/cgiemail/yourdomain/yoursubdirectory/mailform.txt">

and  

c)  The link to the thank you page secure:

<input type="hidden" name="success" value="https://wwwXXXX.securedweb.net/yourdomain/yoursubdirectory/thanks.html">

Having Us Set Up a Form for You

Office On Web can setup your form for you at our standard hourly rates for html. We can also develop custom secure forms or shopping carts. To request us to do this use the Technical Contact Form and specify:

  • the e-mail address which the form submission would go

  • the name of the thank you page

  • all the fields of boxes for the visitor to fill in

For some very useful information on cgi scripts, please consult our CGI FAQ.


 

OfficeOnWeb
261 Hines Road
Polk. PA 16342
Main Phone: 301-591-1745
FAX (call for number)
Toll free is available for clients only (call for number)
Copyright © 1993-2005 by Office on Web of Evergreen Colorado