The University of Arizona

General comments

No matter what type of output you decide to go with, you need to provide some type of feedback to your user after he/she clicks on the Submit button to send form data to you.

The success template that will display for the user is an HTML document. It has to have either an extension of .htm or .html, depending on which extension you are using for your documents. Because this is an HTML document, you could add logos or graphics for your site on this document, use backgrounds or colored fonts, or even use the table feature in this document.

Adding in a reference to the success message

You need to tell Formhandler which document should be used for feedback to the site visitor who fills out your form. This is a HIDDEN INPUT statement within the form area itself. The syntax for the reference to your HTML template for feedback would look like:

<INPUT TYPE="hidden" NAME="success_html_template" VALUE="/usr4/directory&filename-for-template">

A real example for a form I work with is:

<INPUT TYPE="hidden" NAME="success_html_template" VALUE="/usr4/general/forms/message-success.html>

Create the success message which will display

The template itself can be located in any directory area you control. It could be in the same directory as the form itself, or in another directory, but I encourage you to put all your files for the form in the same folder. The template is an HTML file and so it can be created entirely in the design mode of Dreamweaver, if you are not referencing any form fields themselves. A sample could look like this:

Notice there is a link back to some part of your site. You need this statement there, since your site visitor will be taken to another part of the AgServer, in terms of the document which displays.

Adding in respondent's entries in the success message

Depending on your form, you may want to display in the success template some or all of the field answers from your form. This is simply to give the user a record, if they want one. This is NOT to allow the user to change any of the fields. Once the user sees the success message, the data typed into the form has been submitted to you or the form's recipient.

For example, in the speaker pool form I have been using, I could show the student the audiences they have volunteered to work with, by putting into the body of the HTML message something like this:

<p>You have volunteered to work with these audiences:<br / >
<<audiences>></p>
<p>If this is wrong, please contact Sally Jones at sjones@ag.arizona.edu right away.</p>

Notice that the field name which is to display in the success document must have double-brackets around it. I have put the code in blue, to draw your attention to it. Because of the double-brackets, you have to type in the references to the field names in the HTML window in Dreamweaver.

This document is part of a set of tutorials related to putting a form on your website. The initial page is found at cals.arizona.edu/ecat/forms/olderforms.html