Oh, and I also thought it might be helpful to mention that your most
recent config example could be made a bit less verbose by moving the
"main" include into the "MainTemplate" event type, and then removing
the "template.main" event handler and corresponding result tag in the
event type, like so:

<event-handler name="page.index" type="MainTemplate">
       <broadcasts />
       <results />
       <views>
               <include name="body" template="pages/index.cfm" />
       </views>
</event-handler>
<event-type name="MainTemplate">
       <after>
               <broadcasts>
                       <message name="templates.header" />
                       <message name="templates.footer" />
               </broadcasts>
               <views>
                       <include name="header" template="templates/header.cfm" />
                       <include name="footer" template="templates/footer.cfm" />
                       <include name="main" template="templates/main.cfm" />
               </views>
       </after>
</event-type>

HTH,

--
Ezra


On Wed, Nov 11, 2009 at 11:50 PM, Ezra Parker <[email protected]> wrote:
> Well, my immediate guess would be that you have a <cfsetting
> enablecfoutputonly="true"> tag lurking somewhere, as that would cause
> the behavior you described if your footer view was wrapped in a
> <cfoutput> block and the other views were not.
>
> --
> Ezra
>
>
> On Wed, Nov 11, 2009 at 10:46 PM, Chuck <[email protected]> wrote:
>>
>> I finally figured out how to get this to work.  But it doesn't make
>> sense, as it isn't like the Getting Started examples.
>>
>> If I put <cfoutput> blocks around each view it works.  What I found
>> out was that anything within <cfoutput> tags was getting rendered,
>> everything outside wasn't.
>>
>> Any idea why I have to do this for templates/main.cfm? (Note the top
>> and bottom <cfoutput> tags.
>> ---- code ----
>> <cfoutput>
>> <html>
>>
>> <head>
>>        <link rel="stylesheet" type="text/css" href="css/stylesheet.css"></
>> link>
>>        <title>SeaRisen - Communication Solutions</title>
>> </head>
>>
>> <body>
>> <h2>Main Template</h2>
>>
>>        <div id="banner">
>>                <cfoutput>#viewCollection.getView("header")#</cfoutput>
>>        </div>
>>
>>        <cfoutput>#viewCollection.getView("body")#</cfoutput>
>>
>>        <div id="footer">
>>                <cfoutput>#viewCollection.getView("footer")#</cfoutput>
>>
>>        </div>
>>
>> </body>
>>
>> </html>
>> </cfoutput>
>>
>>
>> >>
>>
>

--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to