in reply to Re: Drop-down list Option Value
in thread Drop-down list Option Value
#!/usr/bin/perl -w require "cgi-lib.pl"; &ReadParse; my %hashOfAnimals = ( "pets.gif" => "Your Favorite Pet", "afghanhd.jpg" => "Big dogs", "austter.jpg" => "Little dogs", "ragdoll2.jpg" => "Cats", "fish1.jpg" => "Fresh water fish", "gerbil.jpg" => "Gerbils", "morganhorse.jpg" => "Horses", "parrot.jpg" => "Parrots", "macaw.jpg" => "Macaws", "toucan.jpg" => "Toucans", "snap.jpg" => "Turtles", "iguana.jpg" => "Iguanas", "sinaloan.jpg" => "Snakes" ); #color.cgi #Warn browser that HTML is coming print &PrintHeader; print <<"eohtml"; <html><head><title>Thanks for responding</title></head> <body bgcolor = "#FFFFFF"><H1>Thank You</H1> <p>What a coincidence, $in{'firstname'} $in{'lastname'}!!</p> <p>My favorite color is $in{'color'} <strong>AND</strong> I Love $hash +OfAnimals{$in{'pet'}}.</p> </body></html> eohtml #End of Program
antirice
The first rule of Perl club is - use Perl
The ith rule of Perl club is - follow rule i - 1 for i > 1
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Re: Drop-down list Option Value
by Happyjack (Novice) on Feb 02, 2003 at 19:58 UTC | |
by katgirl (Hermit) on Feb 03, 2003 at 09:21 UTC |