kutsu has asked for the wisdom of the Perl Monks concerning the following question:
The actual error I'm getting is this: Can't locate object method "splitdir" via package "File::Spec" at /usr/lib/perl5/site_perl/5.005/HTML/Template.pm line 2171.
My first template looks like this:
<html> <head> </head> <body> <h2><TMPL_VAR NAME=FOO> Look for something before <b>Look</b></h2> <TMPL_INCLUDE NAME='test2.tmpl'> </body> </html>
My included template:
<h2>This is the second template</h2>
And my code looks like this:
#!/usr/bin/perl use HTML::Template; $template = HTML::Template->new(filename => 'test.tmpl', path => '/path/to/template'); $template->param(FOO => 'foobar'); print "Content-Type: text/html\n\n", $template->output;
I'm using perl 5.005_03 and the latest version of HTML::Template. Thanks all for the help.
"Pain is weakness leaving the body, I find myself in pain everyday" -me
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Problem using TMPL_INCLUDE in HTML::Template
by dragonchild (Archbishop) on Dec 23, 2003 at 14:40 UTC |