cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject Re: AW: AW: AW: AW: Design note - Building a template mechanism
Date Fri, 08 Apr 2005 07:48:08 GMT
hi thorsten

it looks _deeper_ than what i had in my mind
i would like to take all look, but i have not play with forrest (until 
now) so please give me some time .. to come back with my impressions from 



On Fri, 8 Apr 2005, Thorsten Scherler wrote:

> Hi,
> I had a look on the wiki page you posted
and it gave me some really good
> ideas for the view plugin I am working on in forrest.
> Together with another plugin (right now called leather but will be
> renamed to ViewHelper) it is following the DispatcherView pattern
> and building a
> unit.
> I am using right now a different approach then you but it seems we are
> trying to solve the same problem.
> Have a look at
> That is a view on a site. The link is the default view for the site but
> you can define a new view for each page of your webapp.
> A view basically contains three tags (for now - it is in a really early
> stage):
> <forrest:view
>   xmlns:forrest="" type="xhtml">
>   <forrest:contract name="meta"/>
>   <forrest:hook name="container">
>    <forrest:contract name="feedback"/>
>   </forrest:hook />
> </forrest:view>
> The view tag's @type determines the final output format. The idea is to
> configure different output formats via a view. That is the biggest
> different to your approach.
> Each forrest:hook will be transformed into a <div/> tag (in html
> output). This tags are designed to help web-designers to freely move
> around and group contracts into design container.
> Each forrest:contract will dispatch a xml file (ViewHelper) that contains
> xsl:stylesheets for the different output formats, a contract can
> implement. For html, the only format that I have implemented so far, we
> have three different kind of templates:
> <xsl:templates name="{contract/@name}-css/>
> Here the contract specific css will be stored.
> <xsl:templates name="{contract/@name}-head/>
> Here goes everything that belongs in the html head. e.g. scripts.
> <xsl:templates name="{contract/@name}-body/>
> Everything that belongs into the body.
> e.g.
> The view follows exactly the pattern shown here: 
> Right now it is implemented for the forrest way of producing the models
> for the view but I am planing to create independent BusinessHelper to
> access all BusinessServices you may have in your application.
> e.g.

> shows that the $config has to be in the presentation model. Right now there are only
forrest core BusinessHelper.
> One workaround is
> where I pass the models via <xsl:param name="main"/> into the ViewHelper. That

> salu2

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message