chingomaster has asked for the wisdom of the Perl Monks concerning the following question:
we are currently planning to invole the Perl Template Toolkit into our Web Development - in the past we just mixed code and layout - a common problem!
Template Toolkit is our choice - especially the ability to compile Template files into much faster Perl Code is working great, and fast.
Now I am wondering, if it is possible to directly compile Templates from our database. Think of this task: The perl script retrieves the Template Layout from our database at script start.
Then the Script should be able to compile the Template to perl-code, and just run from the perl-code! This is - as i see it - only possible if I retrieve the Template files from the file system.
eg. if I use this Template file:
/templates/one.tmpl
it creates:
/templates/one.tmpl.pp (compiled template)
Is it possible to use the compiling mechanism when retrieving data directly from Database? e.g compiling the Template into a (referenced) scalar and just run this scalar?
Many Greetings
chingomaster
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Perl Template Toolkit / DB Caching
by gam3 (Curate) on Mar 30, 2005 at 12:27 UTC | |
|
Re: Perl Template Toolkit / DB Caching
by lachoy (Parson) on Mar 30, 2005 at 12:57 UTC | |
|
Re: Perl Template Toolkit / DB Caching
by merlyn (Sage) on Mar 30, 2005 at 13:59 UTC | |
|
Re: Perl Template Toolkit / DB Caching
by ryantate (Friar) on Mar 30, 2005 at 19:30 UTC |