I'm not sure if question is supposed for this forum or CGI or Ajax General Discussion, but I'll ask here & if advised will go there as well.
Basically, I'm trying to get the data in the 2nd dropdown to be based on what the user choose in the first. I did not have access to AJAX before, but now it's available.
Below is generic from the module documentation
Basically, I'm trying to get the data in the 2nd dropdown to be based on what the user choose in the first. I did not have access to AJAX before, but now it's available.
Code:
use CGI;
use CGI::Ajax;
my $cgi = new CGI;
my $pjx = new CGI::Ajax( 'exported_func' => \&firstSub );
print $pjx->build_html( $cgi, \&Show_HTML);
sub firstSub {
my $input = shift;
my $output = do some stuff;
&secSub($output); --> this is not working; which will populate the data in 2nd option & then I can do the same for 3rd & 4th drop downs.
return( $output );
}
Below is generic from the module documentation
Code:
sub Show_HTML {
$html<<EOF
<html>
<body>
<table>
<select name=....>
</select>
EOF
return $html;
}