maximo1970
ISP
Let's start of with the code :
my $cur = $dbh->prepare("SELECT Device_Name FROM tbl_admin_systems"
$cur->execute();
my $menudata = $cur->fetchall_arrayref();
my $q = CGI->new;
my $action = "/cgi-bin/serverstatus.pl?";
my $menu_value = $q->url_param('ServerList');
my $submit = $action.$menu_value;
print $q->header;
print $q->start_html(-title=>'Menu');
if (!$q->param) {
print $q->start_form();
print $q->popup_menu(-name=>'ServerList', -values=>[map {$_->[0]} @{$menudata}]);
print $q->br;
print $q->br;
print $q->submit(-name=>'Status Report');
print $q->end_form;
} else {
print $q->parm(Status Report);
}
print $q->end_html;
$cur->finish();
What I'm trying to acheive is an new html page created using the action '/cgi-bin/serverstatus.pl' plus the menu selection such as 'SVR1'. The resulting url would be
Not to sure where I'm going wrong or if this is possible to do.
Cheers
my $cur = $dbh->prepare("SELECT Device_Name FROM tbl_admin_systems"
$cur->execute();
my $menudata = $cur->fetchall_arrayref();
my $q = CGI->new;
my $action = "/cgi-bin/serverstatus.pl?";
my $menu_value = $q->url_param('ServerList');
my $submit = $action.$menu_value;
print $q->header;
print $q->start_html(-title=>'Menu');
if (!$q->param) {
print $q->start_form();
print $q->popup_menu(-name=>'ServerList', -values=>[map {$_->[0]} @{$menudata}]);
print $q->br;
print $q->br;
print $q->submit(-name=>'Status Report');
print $q->end_form;
} else {
print $q->parm(Status Report);
}
print $q->end_html;
$cur->finish();
What I'm trying to acheive is an new html page created using the action '/cgi-bin/serverstatus.pl' plus the menu selection such as 'SVR1'. The resulting url would be
Not to sure where I'm going wrong or if this is possible to do.
Cheers