Multiple Popup Menus Without Layout Control
#!/usr/bin/perl -w

use CGI qw(:standard);
use CGI::Carp qw(fatalsToBrowser);

print header, start_html;
print start_form,
      p("Pick Your Favorite Food From Within Each Group"),
      p("Meat"),
      popup_menu(-name => "meat", -values => ["beef", "lamb", "pork",
                                              "chicken", "fish"]),
      p("Dairy"),
      popup_menu(-name => "dairy", -values => ["milk", "ice cream",
                                               "cheese", "yogurt"]),
      p("Vegetable"),
      popup_menu(-name => "veggie", -values => ["peas", "squash",
              "broccoli", "carrots", "brussel sprouts", "green beans"]),
      p("Starch"),
      popup_menu(-name => "starch", -values => ["corn", "rice",
                                                "potato", "oats", "bread"]),
      submit(-name => "Submit Favorites"),
      end_form;


if (param("Submit Favorites"))
{
      $favorites = join(", ", param("meat"), param("dairy"), param("veggie"),
                              param("starch"));
      print p("Your favorite foods are: $favorites\n");
}
      
print end_html;