PERL:



              

PERL: - . 667


# if ($count) {

$color = $colors[0] unless grep { $_ eq $color > colors;

$size = $sizes[0] unless grep { $_ eq $size } sizes;

param("shirt_color", $color);

param("shirt_size", $size);


700 19 CGI 19.9 ()

unless ($active) <

print hidden( shirt_size ) if $size, print hidden( shirt_color ) if $color, print hidden( shirt_count ) if $count, return,

print M( T-Shirt ),

print p( What a shirt1 This baby is decked out with all the options It comes with full luxury interior, cotton trim, and a collar , to make your eyes water1 Unit price \$33 00 ),

print h2( Options )

print p( How Many9 , textfield( shirt_count )),

print p( Size' , popup_menu( shirt_size , \@sizes ), Color7 , popup_menu( shirt_color , \@colors)),

shop_menu(),

# sub sweater {

my $active = shift,

my sizes = qw(XL L M),

my colors = qw(Chartreuse Puce Lavender),

my ($size, $color, $count) =

(param( sweater_size ), param( sweater_color ), param( sweater_count

# if ($count) {

$color = $colors[0] unless grep { $_ eq $color } colors,

$size = $sizes[0] unless grep { $_ eq $size } sizes,

param( sweater_color , Scolor),

param( sweater_size , $size),

unless (Sactive) {

print hidden( sweater_size ) if $size, print hidden( sweater_color ) if $color, print hidden( sweater_count ) if $count, return,

print h1( Sweater ),

print p( Nothing implies pretty elegance more than this fine , sweater Made by peasant workers from black market silk, it slides onto your lean form and cries out Take me, , for I am a god' Unit price \$49 99 ),


19.14. : chemisene 701

print h2( Options ),

print p( How Many? , textfield( sweater_count ))

print p( Size9 , popup_menu( sweater_size , \@sizes)),

print p( Color' , popup_menu( sweater_color , \@colors)),

shop_menu(),

sub checkout {

my Sactive = shift,