Syntactic Confectionery Delight | |
PerlMonks |
comment on |
( [id://3333]=superdoc: print w/replies, xml ) | Need Help?? |
Hello Monks! After a long hiatus from the site, I'm back again :) I've been toying with a side pet project for publishing HTML files. What I'm trying to achieve is similar to what ActionView, and other templating tools do. In publish.pl, let's say I have a subroutine 'layout' that has local variables $headline, $body, $url. Within this sub, I'd like to call another script 'article.layout.pl', but with the local variables $headline, $body, and $url available to the script. 'article.layout.pl' would then use these variables to print out the final layout. In publish.pl
In article.layout.pl
I realize I could use TemplateTookit to achieve this, but I was hoping to learn how to call mess with perl scoping in general. Thanks fellow monks! It's good to be back. In reply to Injecting local variables into a template by MistaMuShu
|
|