[Previous] [Contents] [Next]


Constructing Elements

You have seen a few examples of how to define fields using CGI::Form. Now let's look at an example of a complete form. What you'll do is create a general questionnaire form for a restaurant. You'll ask the user these things: What did you order? (text field)

How was the service? (radio group)

How did the food taste? (radio group)

What is your age group? (popup menu)


 Would you come back again? (checkbox)


The Perl code in Listing 4.1 generates these fields using a multipart/form-data type form.

[Previous] [Contents] [Next]