in reply to Sorting an array
use CGI; %month_array = ( '01' => "Jan", '02' => "Feb", '03' => "Mar", '04' => "Apr", '05' => "May", '06' => "June", '07' => "July", '08' => "Aug", '09' => "Sep", '10' => "Oct", '11' => "Nov", '12' => "Dec" ); print CGI::popup_menu(-name=>"month_array", -values=>[sort {$a cmp $b} keys %month_array], -labels=>\%month_array, -default=>$mon, -class=>"formfield")
John J Reiser
newrisedesigns.com
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Re: (nrd) Sorting an array
by powerhouse (Friar) on Feb 15, 2003 at 00:38 UTC | |
by newrisedesigns (Curate) on Feb 15, 2003 at 01:09 UTC |
In Section
Seekers of Perl Wisdom