Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

how can i change positions of drop down box

Status
Not open for further replies.

6681510

Programmer
Aug 29, 2007
16
FI
iam creating a cgi page of offer calculator and the code which i have rite now is ...

#!/usr/bin/perl -w

use CGI qw:)all);

print header;

##creating html page
print start_html('Offer Calculator'),
h1(' Offer Calculator'),
start_form,
"Work Station Product: ",
popup_menu(-name=>'WrokStation_products',
-values=>[' Client Security',' For workstation',' Linux Client Security']),
p,
"Suites Product: ",
popup_menu(-name=>'Suites_products',
-values=>[' Client Security',' For workstation',' Linux Client Security']),
p,
"Server products Product: ",
popup_menu(-name=>'Server_products',
-values=>[' for Microsoft Exchange','Internet Gatekeeper','Internet Gatekeeper for Linux',' for Windows Servers',' Linux Server Security']),
p,
"Total Number of Computers: ",textfield('number_of_computers'),
p,
submit,
end_form,
hr;
print end_html;


Now i would like to know how can i put dropdown box and labels in a table.Please give some examples thanks
 
Take a look at the CGI Module on CPAN it will answer ur question.

below is directly from the module documentation.

Code:
print table({-border=>undef},
           caption('When Should You Eat Your Vegetables?'),
           Tr({-align=>CENTER,-valign=>TOP},
           [
              th(['Vegetable', 'Breakfast','Lunch','Dinner']),
              td(['Tomatoes' , 'no', 'yes', 'yes']),
              td(['Broccoli' , 'no', 'no',  'yes']),
              td(['Onions'   , 'yes','yes', 'yes'])
           ]
           )
        );

OR you can use print statment where the table needs to be inserted i.e

print "<table>";
print "<tr><td>"; and so on.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top