The last step in creating a form is deciding where to put all the information you've gathered. Your choices are the following:
The first three options require a Web server that supports FrontPage Server Extensions. Form data that is mailed will arrive like any other email. The name and value of each form element will be displayed in the body of the email, as in the following: FullName: Puddin N. Tane Title: Mr. THX-1138: Own ROOM-222: Own Purpose: Complaint To save a form to a file, you specify the filename and folder where it should be stored. If this file doesn't exist when someone uses the form, it will be created.
The last way to handle forms is to call up a program on your Web server that can take in form data and do something with it. (Most of these programs simply email the data to a specified address.) Form-handling programs rely on the Common Gateway Interface (CGI), a protocol that determines how a Web server exchanges information with other programs on the same computer. CGI programs require special access to a Web server, and most Web hosting services don't grant it to their customers for security reasons. Some hosting services install CGI programs that can be shared by all customers. If you have a CGI program that handles forms, all you need to do in FrontPage is specify the name and location of the program and its delivery method. The method is either POST or GET , and the documentation for the CGI program should specify which one to use. Figure 40.11 shows how this information is configured in FrontPage. Figure 40.11. Calling a CGI program to handle a form.
Figure 40.12 shows a Web form that includes every form element described here except pictures. Figure 40.12. An intrusive Web form.
Creating this form took the following steps:
An extra step was involved in the creation of the radio buttonsall of these buttons were given the same group name. After the drop-down menu was placed on the form, items were added to it by double-clicking the menu and using its Properties dialog box. If the form shown in Figure 40.12 was submitted to an email address, it would arrive looking like the following: ************************************************************************* Name: Rogers Cadenhead StreetAddress: 201 W. 103rd St. City: Indianapolis StateOrProvince: IN ZipOrPostalCode: 46290 Age: 30-39 Favorite80sTVShow: Joanie Loves Chachi LeastFavoriteIceCreamFlavor: Pistachio Tattoo: What? Tattletale: ON EmailAddress: frontpage24@prefect.com MostEmbarrasingThing: I bought two copies of Microsoft Bob and recommended it highly to others. |