I've been trying to get a grasp on event flow, and it seems to me that
event-type's <before> tag, the things defined in there should execute
BEFORE everything else in the event that includes that event type in
its Type property.
Tell me is this a feature or bug ... some code
<event-type name="beforeMainTemplate">
<before>
<results>
<result do="templates.header" />
</results>
</before>
</event-type>
The Event...
<event-handler name="templates.header">
<broadcasts>
<message name="templates.header" />
</broadcasts>
<results />
<views>
<include name="header" template="templates/header.cfm" />
</views>
</event-handler>
The event that includes the Type
<event-handler access="private" name="template.main"
type="beforeMainTemplate">
<broadcasts>
<message name="templates.footer" />
</broadcasts>
<views>
<include name="footer" template="templates/footer.cfm" />
<include name="main" template="templates/main.cfm" />
</views>
</event-handler>
I've tried this with the footer event, but get the same results, see
below
The debug output...
765ms Views Rendering view "body" (pages/index.cfm)
<include name="body" template="pages/index.cfm" />
765ms Views Rendering view "footer" (templates/footer.cfm)
<include name="footer" template="templates/footer.cfm" />
781ms Views Rendering view "main" (templates/main.cfm)
<include name="main" template="templates/main.cfm" />
781ms Views Rendering view "header" (templates/header.cfm)
<include name="header" template="templates/header.cfm" />
Why is it that the view is rendered last when it is in a <before>
tag? Again is this a feature or bug?
--~--~---------~--~----~------------~-------~--~----~
Model-Glue Sites:
Home Page: http://www.model-glue.com
Documentation: http://docs.model-glue.com
Bug Tracker: http://bugs.model-glue.com
Blog: http://www.model-glue.com/blog
You received this message because you are subscribed to the Google
Groups "model-glue" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/model-glue?hl=en
-~----------~----~----~----~------~----~------~--~---