Hi
i am trying to make a global that will return a list of the categories and their IDs in a select field
sub {
my $tags = shift;
my $cat_db = $DB->table('Category');
$cat_db->select_options("ORDER BY Full_Name");
my @root_cats = $cat_db->select (['Full_Name'], ['ID'])->fetchall_list;
my $output;
foreach my $cat (@cats) {
my $ID = $cat_db->as_id($cat);
$output .= qq~<option value="$ID">$cat~;
}
return $output;
}
The above global returns errors and suggestions to fix it..
Regards
KaTaBd
Users plug In - Multi Search And Remote Search plug in - WebRing plug in - Muslims Directory
i am trying to make a global that will return a list of the categories and their IDs in a select field
sub {
my $tags = shift;
my $cat_db = $DB->table('Category');
$cat_db->select_options("ORDER BY Full_Name");
my @root_cats = $cat_db->select (['Full_Name'], ['ID'])->fetchall_list;
my $output;
foreach my $cat (@cats) {
my $ID = $cat_db->as_id($cat);
$output .= qq~<option value="$ID">$cat~;
}
return $output;
}
The above global returns errors and suggestions to fix it..
Regards
KaTaBd
Users plug In - Multi Search And Remote Search plug in - WebRing plug in - Muslims Directory