Hello Ajay

On 2/23/07, Ajay Maurya <amaurya@brickred.com> wrote:
Hi

  I have installed mod_perl and apache I am getting error message below

[Fri Feb 23 11:21:45 2007] [error] HTML::Template->new() : Cannot open
included file fruit.tmpl : file not found.


I would use a relative path, it is a little uncetain which will be the Apache CWD, in order tu use relative path to it.

You can store a base path in a configuration file or in the Apache config (using $r->dir_config()) and the construct the template path before each call to HTML::Template

matías
--
http://confronte.com
Compará y comprá mejor
 

at /usr/lib/perl5/site_perl/5.8.8/HTML/Template.pm line 1658\n
\tHTML::Template::_init_template('HTML::Template=HASH(0x80bafe5c)')
called at /usr/lib/perl5/site_perl/5.8.8/HTML/Template.pm line 1238\n
\tHTML::Template::_init('HTML::Template=HASH(0x80bafe5c)') called
at /usr/lib/perl5/site_perl/5.8.8/HTML/Template.pm line 1124\n
\tHTML::Template::new('HTML::Template', 'filename', 'fruit.tmpl') called
at /var/www/html/perl/fruit.pl line 12\n
\tModPerl::ROOT::ModPerl::Registry::var_www_html_perl_fruit_2epl::handler('Apache2::RequestRec=SCALAR(0x809da4c8)') called at /usr/lib/perl5/vendor_perl/5.8.8/i386-linux-thread-multi/ModPerl/RegistryCooker.pm line 203\n\teval {...} called at /usr/lib/perl5/vendor_perl/5.8.8/i386-linux-thread-multi/ModPerl/RegistryCooker.pm line 203\n\tModPerl::RegistryCooker::run('ModPerl::Registry=HASH(0x809da57c)') called at /usr/lib/perl5/vendor_perl/5.8.8/i386-linux-thread-multi/ModPerl/RegistryCooker.pm line 169\n\tModPerl::RegistryCooker::default_handler('ModPerl::Registry=HASH(0x809da57c)') called at /usr/lib/perl5/vendor_perl/5.8.8/i386-linux-thread-multi/ModPerl/Registry.pm line 30\n\tModPerl::Registry::handler('ModPerl::Registry', 'Apache2::RequestRec=SCALAR(0x809da4c8)') called at -e line 0\n\teval {...} called at -e line 0\n


when i use absolute path for fruit.tmpl file then only it works and when
i use relative path i does not work . Can anyone help me out


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys-and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Html-template-users mailing list
Html-template-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/html-template-users