The second example in the Template Toolkit documentation shows how to pass it a string for the template:
# text reference $text = "[% INCLUDE header %]\nHello world!\n[% INCLUDE footer %]" +; $tt->process(\$text) || die $tt->error(), "\n";
In reply to Re^3: 'Here Documents' and unrecognized escapes
by Corion
in thread 'Here Documents' and unrecognized escapes
by morelenmir
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |