To expand on injunjoel's reply, try:
use CGI; my $query = new CGI; if ($query->param("item") eq "select") { &retrieve_data; } elsif ($query->param("item") eq "update") { &update_data; } sub retrieve_data {
That should do it. It's one of those crazy bugs that we have all stared at for hours and simply not seen the obvious. Take heart, we've all been there.
In reply to Re: Use 'param' in if statement.
by bradcathey
in thread Use 'param' in if statement.
by krachen
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |