I am not sure if this is the right place for this question.
Well here is goes.
I have CGI::Application working. Now I want to expand on how I use it. It
would seem that I could have a template page where I have two run modes
called. Well, not two run mode but two function from the script are called
with two seperate template pages that are put into the main template page.
For example I would like to do something like this.
<table>
<tr>
<td>
Title Output
</td>
</tr>
<tr>
<td>
Main Page stuff
</td>
</tr>
</table>
>From the examples in the docs i am thinking of something like this, but this
road seems like it is leading to nowhere.
sub do_more_stuff {
my $self = shift;
my $q = $self->query();
my $output = '';
$output .= '<table> <tr> <td>';
$output .= 'PRINT THIS';
$output .= '</td> </tr> <tr> <td>';
$output .= do_title_stuff();
$output .= '</td> </tr> </table>';
$output .= $q->end_html();
}
sub do_title_stuff {
my $self = shift;
my $template = $self->load_tmpl('title.tmpl'); <-- line 67
return $template->output();
}
Here is the error output I get.
Error executing run mode 'mode2'. Eval of code '$self->do_more_stuff'
resulted in error: Can't call method "load_tmpl" on an undefined value at
/usr/local/apache/vhosts/mooky/modules/WidgetView.pm line 67.
[Tue Feb 11 11:33:44 2003] [error] [client 192.168.1.104] Premature end of
script headers: /usr/local/apache/vhosts/mooky/cgi-bin/cgiapp.pl
I am not sure where to go from here.
Thanks
Douglas Kirkland
---------------------------------------------------------------------
Web Archive: http://www.mail-archive.com/suppressed/
To unsubscribe, e-mail: suppressed
For additional commands, e-mail: suppressed
Mail converted by mhonarc 2.6.15
This archive provided courtesy of JSW4.NET, Internet Hosting Services for Small Business.