Gossamer Forum
Home : General : Perl Programming :

PopUp_Menu

Quote Reply
PopUp_Menu
  Howdy,
I want to use a Select menu using the CGI.pm module. I assume that I'm going to use a popup_menu method call but I'm not sure on the syntax I was based on the array I have.

I want all the values of the array to be the values of the select box
EX
Code:
@arrayName = qw(one two three four);
... do form inititialization ..
$cgiObj -> popup_menu(-name=>'popupname',
-values=>@arrayName);
.. end form ...
is this valid sytax or do I have to iterate through the array for the values?

s0crates
-- If practice didn't make perfect, what would it do? --

Last edited by:

s0crates: Aug 29, 2002, 9:06 AM
Quote Reply
Re: [s0crates] PopUp_Menu In reply to
Try:

Code:
$cgiObj->popup_menu( 'popupname', \@arrayName );

http://www.perldoc.com/...NG-DYNAMIC-DOCUMENTS