[an error occurred while processing this directive] The WebCom Forms Processor - Output Formats

This page describes the details of creating formatted output(s) from your fill-out forms, using the WebCom forms processor.

Use a format (instead of simple parameter setttings) if you want a more customized format for the email message or file you're creating with your form, or when you want to include dynamic values on the screen displayed to the user after the form's submitted (without having to write the dynamic values to a file and then display the file with the screen parameter).

Formats are included anywhere in your configuration file. A format starts with the format statement on one line, is followed by one or more lines of format pictures and field names, and ends with a period (.) as the first character on a line, all by itself.

Each format statement has at least 3 lines:

You can have any number of formats in the form configuration file. Each format defines what is written to a particular file, email address, or the users's screen (after the form has been submitted and processed).

Here's two sample formats used by a feedback form which allows a user to send an email message with a fill-out form. Click on the above three component links for a detailed explanation of each component of these formats:

format email to admin@webcom.com from $email_addr subject "$subject" name "$name"

Name:           $name
Email Address:  $email_addr
Comments: 
$comments
.
format screen
<HTML><HEAD><TITLE>Feedback Form</TITLE></HEAD>
<BODY>
<H1>Thank You!</H1>
<H2>We value your input.  We'll read and respond to your note as soon as possible.</H2>
</BODY>
</HTML>
.

This is actually the configuration file for our feedback form. By looking at it, you can see that the form contains fields called email_addr, subject, name, and comments.

This configuration file does two things: it sends an email message to admin@webcom.com with the person's name, email address, and comments in a nicely formatted message, and displays an acknowledgement to the user's screen thanking them for their feedback. Because we included 'from $email_addr' in the format statement for the email message, the message will appear to have come from their mailbox, so when we respond to the message, it goes to them correctly. We've also instructed the form processor to use what they typed into the subject field as the subject of the email message sent to admin@webcom.com.

[an error occurred while processing this directive]