On Sat, 31 May 2003, Andy Wardley wrote:

> Here's an easier way.
> 
>   package Template::Provider::Allow;

Thanks a lot, it works very well. I do not like to alter the standard tt2 
distribution, for future compatibility. I hope it will be inserted in the 
next distribution, too.

Anyhow, I'm playng with a tt2 wiki and I found the following problem. 

For the moment each page is essentially like:

[% header %]
[% TEXT | eval %]
[% footer %]

where TEXT is the page content inserted by the user. In the future, when I 
will be able to control inclusions it will become 

[% header %]
[% PROCESS textfile %]
[% footer %]

but for the moment I read the text in  a perl script. 

The problem: if TEXT contains an invalid tt2 directive the whole page is 
affected. I tried to surround the text with TRY/CATCH but it does not work 
for syntax errors. Have I missed something? 

A final point: if one wants to change the start-end tags in the config, 
and wants brackets, he has to write for instance

$config = {
....
                START_TAG    => '\[\+',   
                END_TAG    => '\+\]',    
}

which is not documented, at least as far I know. 



-- 
Franco Bagnoli (franchino) <[EMAIL PROTECTED]> ([EMAIL PROTECTED])
virtual location: Dipartimento di Energetica "S. Stecco"
real location: Dip. Matematica Applicata "G. Sansone", Universita' Firenze,
Via S. Marta, 3 I-50139 Firenze, Italy. Tel. +39 0554796422, fax: +39 055471787
GPG Key fingerprint = 169D 9EA5 8FD3 7EDA E43A  9830 255F BCEC 0D63 3728


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

Reply via email to