Mark Anderson wrote:
> rather, i'd like to be able to INCLUDE or PROCESS a file like this:
>  [%INCLUDE common]
>  [% FOREACH row = DBI.query('SELECT * FROM tablename ORDER BY sortorder') %]

That should be:
  [% PROCESS common %]

If you INCLUDE it then any variables (including plugins) defined in the
common template remain local to it.  Use PROCESS so that variables are
"exported" into the calling template.

Also, see the PRE_PROCESS option.  This will automatically add it to all
your template pages.

A


_______________________________________________
templates mailing list
[EMAIL PROTECTED]
http://lists.template-toolkit.org/mailman/listinfo/templates

Reply via email to