[Petal] petal include: modifier

William McKee william at knowmad.com
Fri Jan 14 18:20:57 GMT 2005


On Fri, Jan 14, 2005 at 05:55:58PM +0000, Fergal Daly wrote:
> I don't see why it would process the original file a second time

Cool. So the order of processing would be something like the following:

 Inside our Petal template:

  <span tal:replace="include: template_name">Some dynamically determined template</span>


 Inside the Petal engine:

  1st process -
      determine name of included file
      call the include: modifier

  Inside the include modifier - 
      modifier retrieves name of template file
      create new Petal object and processes the file
      return output to 1st process

  1st process -
      continue processing


> the first ->process just finds the name of the included file, ->new loads it
> and the second ->process processes the included file.

Yeah, looking at it like this does make it appear that it wouldn't be
processed twice. Perhaps Josh can find the discussion where that issue
came up.


William

-- 
Knowmad Services Inc.
http://www.knowmad.com


More information about the Petal mailing list