this has to be something simple! i have a form that builds five radio fields: column-1, column-2, etc. when the form is submitted, i want to display the value that was selected. while testing, i'm using the following:
print qq|<tr><td>column-$count $in{'column-$count'}</td></tr>|;
$count++;
}
foreach $key (sort keys %in) {
if ($key =~ /column/) {
print "<tr><td>$key: $in{$key}</td></tr>\n";
}
}
the display looks like this:
column-1
column-2
column-3
column-4
column-5
column-1 Title
column-2 Description
column-3 Category
column-4 Updated
column-5 Approved
the first one doesn't work but is the one i want to use! the second one does work (displays the values selected) but i don't want to use it for other reasons. i can't figure out what's wrong with $in. i've tried it with and without the single quotes with same result.
Code:
while ($count < 6) { print qq|<tr><td>column-$count $in{'column-$count'}</td></tr>|;
$count++;
}
foreach $key (sort keys %in) {
if ($key =~ /column/) {
print "<tr><td>$key: $in{$key}</td></tr>\n";
}
}
column-1
column-2
column-3
column-4
column-5
column-1 Title
column-2 Description
column-3 Category
column-4 Updated
column-5 Approved
the first one doesn't work but is the one i want to use! the second one does work (displays the values selected) but i don't want to use it for other reasons. i can't figure out what's wrong with $in. i've tried it with and without the single quotes with same result.