From: Eric W. <li...@bw...> - 2005-02-28 15:28:56
|
> [[.import name=transform ]] > [[ transform.expr('ignore_none') ]] > > But the header could also contain other initialisation. This would be > similar to a feature in PHP, IIRC called 'auto_prepend_header'. Another implementation of this idea to consider modeling is HTML::Mason's autohandlers. This is similar to auto_prepend_header and auto_append_footer in PHP, except they're automatically applied (based on filename) and are nested. Example, say you have the following files: /autohandler /dir1/autohandler /dir1/index.html Requests for index.html will execute /autohandler, /dir1/autohandler, and finally /dir1/index.html. Each child is stored as a method you can call, the stdout is redirected to the return value of the method. It is possible, even now, to do this with Spyce without any changes to the code, but it isn't easy or obvious enough. |