Once a form on a web server is filled in and submitted, a server CGI (Common
Gateway Interface) set in <form action=>, processes the data collected.
This program will take the information from RIT web forms and mail it to
the designated user.
Modifying Your First Web Form
<HTML>
<HEAD><TITLE>Web Feedback Form</TITLE> </HEAD>
<BODY TEXT="000000" BGCOLOR="#FFFFFF" >
<center> <H2>Feedback to Web Page Maintainer</H2></center>
This form allows you to send automatic mail to [put_your_name_here], at Rochester
Institute of Technology. Please use this form to report problems with this web
page or to make suggestions or comments about the Web design or content. <P>
<FORM Action="http://www.rit.edu/cgi-bin/gmail.cgi" Method="POST">
This mail will be sent to
<INPUT Type="hidden" Value="your_username@rit.edu" Name="mailto">
the web page author (for problems or comments with this web page)<p>
<input type=hidden name=redirect value="http://www.rit.edu/~your_usename">
This is a <SELECT Name="Type">
<OPTION>Comment
<OPTION>Suggestion
<OPTION>Problem Report
</SELECT>
<PRE>
Please enter your first and last name: <INPUT Type="text" Name="Name" Size=30><BR>
Please enter your e-mail address: <INPUT Type="text" Name="email" Size=30><BR>
Please enter a subject for your message: <INPUT Type="text" Name="subject"
Size=30><BR>
</PRE>
Please check all the apply:<br>
<input name="RIT_Faculty" type="checkbox" value="yes">I am an RIT faculty
member<BR>
<input name="RIT_Staff" type="checkbox" value="yes">I am an RIT staff
member<BR>
<input name="RIT_Student" type="checkbox" value="yes">I am an RIT student<BR>
<input name="Outside_RIT_Other" type="checkbox" value="yes">Other, Please
tell me where you are from:<BR>
<TEXTAREA NAME="Other_explain" ROWS=2 COLS=35></textarea><p>
I would like a response to my comment or suggestions. <INPUT Type="radio"
Name="Respond_by_Email" Value="Yes">Yes OR <INPUT Type="radio" Name="Respond_by_Email"
Value="No">No <br><br>
Please enter the text of your message in the space below. The text will scroll,
so you have space.<P>
<TEXTAREA Name="Text" Rows=5 Cols=70></TEXTAREA><BR> <BR>
Thank you. Please <INPUT Type="submit" Value="Press to Send"> or <INPUT
Type="reset" Value="Press to Reset">
</FORM> </BODY> </HTML>
| Form Element |
Explanation |
| <FORM Action="http://www.rit.edu/cgi-bin/gmail.cgi" Method="POST"> |
Form Action is a required element that points to the program on the web
server that will process the form information. gmail.cgi can only be used
within the rit.edu domain. |
| <INPUT Type="hidden" Value="your_username@rit.edu" Name="mailto"> |
This line will not show in the form because it is hidden, but is required.
The value= the internet address to send to Name="mailto" is a requirement
of gmail.cgi |
| <input type=hidden name=redirect value="http://www.rit.edu/~your_usename"> |
This hidden value is optional. After the form is submitted, this is the
designated URL is where the user will be returned. If you do not designate
a URL a simple thanks page with a return link to the RIT homepage will appear. |
This is a <SELECT Name="Type"> <OPTION>Comment
<OPTION>Suggestion
<OPTION>Problem Report
</SELECT>
|
This is a pop-up menu. Option are the items that appear in the list. |
| Please enter your e-mail address: <INPUT Type="text" Name="email" Size=30><BR>
Please enter a subject for your message: <INPUT Type="text" Name="subject"
Size=30><BR>
|
Fill-in the blank. The type is text. The name should designate what information
you are collecting (name, email, subject, etc.) Size=30 is the size of the
blank. Use a number of your choice. |
| Please check all the apply:<br>
<input name="RIT_Faculty" type="checkbox" value="yes">RIT faculty<BR>
<input name="RIT_Staff" type="checkbox" value="yes">RIT staff<BR>
|
Checkboxes allow more than one response. Name should be different showing
what they choose, type=checkbox and value is always yes. Type text next
to the tag for the choice (can be same as name) |
| <INPUT Type="radio" Name="Respond_by_Email" Value="Yes">Yes OR <INPUT
Type="radio" Name="Respond_by_Email" Value="No">No < |
Radio buttons allow one choice of many. The name must be the same. Type
is radio button and Values are different. (yes, no or 1,2,3,etc.) |
| <TEXTAREA Name="Text" Rows=5 Cols=70></TEXTAREA><BR> |
Text Area is a scrollable writing area. Size is designated by different
numbers of rows and columns. |
| <INPUT Type="submit" Value="Press to Send"> or <INPUT Type="reset"
Value="Press to Reset"> |
Submit and Reset buttons. Type is submit or reset. Value= wording to appear
on buttons |