Forms - A Brief Explanation

Purpose

HTML forms collect information from readers of your pages. The information might be orders, quiz answers, comments, or opinions. The way that you design the form can give the respondent as little or as much leeway as you wish in what answers he or she selects.

Three Steps

As the drawing below suggests there are three steps to form processing.
  1. Data is entered on the form by the respondent who "clicks" on a button to submit it when it is ready.
  2. Once the submission occurs, the HTML script calls the program identified in the ACTION parameter field of the FORM tag. The data is passed to this program for processing. In the Le Cafe Cyber example, the information collected on the form, along with hidden data specified by the form developer, is passed to a program which reformats the data and creates an email message.
  3. The finalresult of the processing may be to send an email message, or store data in a file or present a new view on a screen.

What You Need to Do

A form is part of an HTML document like a list or a table. To create a form you must The value for the ACTION parameter, refers to a file containg the program that will process the information from the FORM. Here at Auburn that may be The Instructional Media Group is building a reference set of general programs (including HTML_SCRIPT templates) that will be available for your use.

A Sample Form

The submit button is disabled (i.e. the ACTION value is a nonexistent file).

 

 

Please enter your name:

 

Pick at least one color:

Red
Green
Blue

 

 

On what day were you born?

 

Choose one:

ON
OFF

 

<FORM ACTION="http://www.auburn.edu/~backsni/do_nothing" METHOD="POST">

Please enter your name:
<INPUT TYPE="text" NAME="TEXTFIELD" SIZE=20 ><B>

Pick at least one color:<BR>
<BLOCKQUOTE> <INPUT TYPE="checkbox" NAME="RED" > Red<BR>
<INPUT TYPE="checkbox" NAME="GREEN" CHECKED> Green <BR>
<INPUT TYPE="checkbox" NAME="BLUE" > Blue </BLOCKQUOTE><BR>

On what day were you born?<BR>
<BLOCKQUOTE><SELECT NAME="DAY_OF_WEEK">
<OPTION> Monday
<OPTION> Tuesday
<OPTION> Wednesday
<OPTION> Thursday
<OPTION> Friday
<OPTION> Saturday
<OPTION> Sunday
</SELECT></BLOCKQUOTE>

Choose one:
<BLOCKQUOTE><INPUT TYPE="radio" NAME="ON_OFF" VALUE="ON" > ON<BR>
<INPUT TYPE="radio" NAME="ON_OFF" > OFF</BLOCKQUOTE><P>

<INPUT TYPE="reset" >
<INPUT TYPE="submit" >
</FORM>

Reference Material