This script will take a web based form and then e-mail the form to any specified recipients as an html document identical to the form but with the values substituted in. Here is a summary of the special fields that can be used to alter the default behavior. Any of these fields can substitute values from other fields by enclosing the other fields inside curly brackets. For example, if the "subject" field has the value of "Request: {LastName}, {FirstName}" the Subject: of the message would be "Request: Dobbs, Bob"
Field Name | Description |
---|---|
to (required) |
Who the recipient (or recipients) of the message should be. Multiple fields can be used to list multiple recipients |
from | Who the sender of the message should be. Defaults to webmaster address. Errors on delivery will be bounced back to this address. |
cc | Additional recipients listed in the Cc: line of the message. Multiple fields can be used to list multiple recipients |
bcc | Additional recipients which are not listed in the message. Also known as Blind Carbon Copy. Multiple fields can be used to list multiple recipients. |
replyto | Add a Reply-To: e-mail header with this value. |
subject | The subject line of the message to be sent. The default is "WWW Form". |
formpage | A full URL for a web page to be used as the template for the e-mail. Default is the web page that of the submitted form (the "refering page"). Note that this page has to have form elements with the same names as the form elements from the submitting form for them to show up in the e-mail. |
redirect | A full URL for a web page to send the user to after the form has been processed. The default behavior is just to display the form as submitted, which may not be the desired effect. |
required | A set of fields separated by commas that must be present in the form to proceed. Multiple "required" fields can be used for readability. |
no-padding | If this field has a value, none of the fields will be padded by their length. |
font-family | The font to use for field values -- default is Courier. |
font-size | The size of the font to use for field values -- default is 0.9em. |
message-body | Text to be sent in the body of the message, prior to the HTML attachment. Default is "Attached please find the contents of a form submitted via the web." |