You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Andy Pahne <a....@skaffen.de> on 2005/04/25 23:00:03 UTC

how to override a components template (not skinning)

I asked this question a few weeks ago, but nobody answered. Unfortunatly
 I could not find an answer myself, in the Wiki or the book. So I try it
again:

I have a component, that is packaged as a library. It contains the
component specification, a Java class file and a (default) template.

Now I want to use this library (the component) in a new application. Is
it possible to override the template that is packaged inside the library
without repackaging the library? The included template should be a kind
of fallback, but I want some customization by using another template.

It would be sufficient, if I could make the choice at deploy-time. There
is no need for dynamic template choosing on each request. No skinning
necessary.

Any suggestions, how I could achieve this?

Andy

---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


Re: how to override a components template (not skinning)

Posted by Jamie <ja...@dang.com>.
Sure. In your WEB-INF/classes folder make the full package of folders 
mirroring the location of your library's template. Put the new one in 
the with the same name in there and it will override the library's template.

Jamie

Andy Pahne wrote:
> I asked this question a few weeks ago, but nobody answered. Unfortunatly
>  I could not find an answer myself, in the Wiki or the book. So I try it
> again:
> 
> I have a component, that is packaged as a library. It contains the
> component specification, a Java class file and a (default) template.
> 
> Now I want to use this library (the component) in a new application. Is
> it possible to override the template that is packaged inside the library
> without repackaging the library? The included template should be a kind
> of fallback, but I want some customization by using another template.
> 
> It would be sufficient, if I could make the choice at deploy-time. There
> is no need for dynamic template choosing on each request. No skinning
> necessary.
> 
> Any suggestions, how I could achieve this?
> 
> Andy
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
> 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org