Storing Form Results


Simply creating a form s public face is one thing, but the next phase is equally important: telling FrontPage what needs to happen with the data the form collects. Processing data submitted via Web page forms is an area where FrontPage really shines. Rather than having to use a program called a Common Gateway Interface (CGI) script to process the data, you can use FrontPage s built-in components to do the work for you. For some forms, you ll want to save the results to a file in your FrontPage-based Web, so that you can work with them later. If the amount of data you re collecting is small, you can also have the results sent to you in the form of an e-mail message.

Saving Form Results in a File

One of the most straightforward ways of handling form data is to save the information to a file so that you can open it and work with it. FrontPage enables you to specify that the data be saved as an HTML file you can open in your Web browser, or as an ASCII text file you can open in any text editor. Just follow these steps:

  1. Right-click anywhere in the form.

  2. Choose Form Properties from the shortcut menu.

  3. Click Send To to send the results to a file on your Web site (see Figure 14-15).

    click to expand
    Figure 14-15: Use this dialog box to save form results to a text file.

  4. Enter a new file name or folder name if you wish to.

  5. Click Browse to locate a folder on your Web site where you want to store the results, instead of the default _private directory.

  6. Click Send To Database to store the results in a database file.

  7. Click Send To Other if you have a custom script you want to use to process the data.

  8. Enter the name of the form in the Form name box, and click OK.

Caution  

The form results are sent, by default, to the folder _private on your Web. This folder cannot be browsed by your visitors , so it makes sense to store form results there because it helps protect the privacy of anyone who fills out the form. Storing it in another publicly accessible folder on your Web can cause big privacy problems that you want to avoid, especially if you re in business. Keep the results in _private, unless you have a compelling reason to put them elsewhere.

Having Form Results E-mailed to You

Another convenient way to save form data is to have the results e-mailed to you. That way, you can access them from any computer that s online, and you can send an e-mail response immediately.

  1. Right-click anywhere in the form, and choose Form Properties from the shortcut menu.

  2. Click Send To to send the results to a file on your Web site.

  3. Delete the contents of the File Name box if you want the results to be only e-mailed to you, and not saved in a file as well.

  4. In the E-mail Address box, enter the e-mail address where you want the form results to be sent, and click OK.

Aha!  

Make Your Form Results Easier to Recognize
It s a good idea to change the default file results file name (form_results) to something more specific, so that you know exactly what the file contains when you want to view it.




Faster Smarter Microsoft Office FrontPage 2003
Faster Smarter Microsoft Office FrontPage 2003
ISBN: 0735619727
EAN: 2147483647
Year: 2004
Pages: 179

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net