[Date Prev][Date Next][Thread Prev][Thread Next][Interchange by date
][Interchange by thread
]
[ic] Open and 'run' a page from within another page--more info
On Thursday 07 November 2002 15:15, you wrote:
> > However, if I use calc tags instead of perl tags, the error
> > log starts displaying a lot of errors like
> >
> > Safe: Undefined subroutine
> > &Vend::Interpolate::somefunction called at ...
> >
> > where somefunction is a function that I include from the catalog.cfg
> > file.
>
> This should not happen. I think it would be of interest to know your
> OS, DB, etc., and whether you took the advice to not use interpolate=1.
I took out interpolate=1, develop on RH7.1, IC 4.8.5/4.8.6. The database used
is postgresql 7.1.2.
As mentioned, I overlooked the global error log; it mentions 'Attempt to call
Perl from within Safe'.
> Also, the error you are getting would indicate you are calling some
> routines -- what are they, pray tell? You can't just call arbitrary
> subroutines in embedded Perl, you know.
I use some library routines included from the catalog.cfg, defined
in files in the following manner:
##########
Sub library <<EOR
sub {
sub dumpcgi {
# Dump CGI variables in alphabetic order.
my $page;
my @keylist=grep $CGI->{$_} ne "" ,sort keys %{$CGI};
foreach my $x (@keylist) {
$page.=$x."=".$CGI->{$x}."<br>\n";
}
return $page;
}
}
EOR
##########
Many of these libraries access database tables with the
Query tag and output HTML.
Hope this clarifies a few things,
Marc Brevoort