Skip to main content.
home | support | download

Back to List Archive

Re: DEFAULT_CONFIG_FILE in 2.2 question

From: Bill Moseley <moseley(at)not-real.hank.org>
Date: Tue Sep 10 2002 - 18:37:15 GMT
At 11:26 AM 09/10/02 -0700, Jody Cleveland wrote:
>When I try swish.cgi from a browser, I get the default layout. When I try
>from a command prompt, I get this error:
>swish.cgi Can't locate Template.pm in @INC etc....
>
>I did a search in all files contained in the swish-e folders and subfolders,
>and template.pm isn't listed in any of them.
>
>Any ideas?

Fifth paragraph of the docs:

       HTML::Template and Template-Toolkit are available from the CPAN
       (http://search.cpan.org).

That paragraph is misleading since it says the modules are in the "modules"
directory.  What's in the modules directory are modules that interface with
Template-Toolkit and HTML::Template.  Those are required because they each
map variables in the swish.cgi script to template variables in different
ways depending on which system you are using.

You need to pick which templating system you want to go with and then
install it.

It might be as simple as:

    perl -MCPAN -e 'install Template'

Oh, if on Windows you might need to use ppm. See:

   http://template-toolkit.org/download.html#win32

I like Template-Toolkit because of it's power, but I think HTML::Template
is nice too (just happen to be editing some HTML::Template templates as
your mail came in...)  I like TT's "ttree" command to build a static site
from templates.  Makes changing the design on an entire site (static and
dynamic content) quite easy.  There's lots of tools that can do that of
course.

-- 
Bill Moseley
mailto:moseley@hank.org
Received on Tue Sep 10 18:40:46 2002