; From: Luther Baker [mailto:[EMAIL PROTECTED]
> Sent: Thursday, October 02, 2008 12:51
> To: Tapestry users
> Subject: Re: template dynamics
>
> Sorry.
>
> My point was to ask for suggestions. My tapestry development is in
> somewhat
> of a Vacuum so looking for some hints for
Sorry.
My point was to ask for suggestions. My tapestry development is in somewhat
of a Vacuum so looking for some hints for this end goal. This process is a
bit point blank... maybe there is a better method to use on the java class
that is a part of the lifecycle of the component. As mentioned ea
I wrote a small custom menu component that includes or doesn't include an
anchor href based on the href of the current page.
I wonder if the block approach suggested here would be cleaner? I use the
following idiom:
http://tapestry.apache.org/schema/tapestry_5_0_0.xsd";>
That's a really nice solution. Have to keep that in mind.
Uli
Am Do, 2.10.2008, 15:49, schrieb Filip S. Adamsen:
> Hi,
>
> Define Blocks containing the different states you need and use a
> Delegate to render the block you need based on an expression. This way
> you can do the whole if-then-else/
Hi,
Define Blocks containing the different states you need and use a
Delegate to render the block you need based on an expression. This way
you can do the whole if-then-else/switch stuff in your page class.
Template:
...
...
Class:
@Inject
private ComponentResources resources;
Indeed switching between states is a bit tedious fiddling because Tapestry
won't just let you write something like "foo==bar" in your expressions.
You'll have to do the more complex checks in your page class. Some of the
trivial checks Tapestry can do on its on (see the If component reference
docum
Hi Uli,
thanks, I did not know about these. However, what if I have to switch
between more states? If seems to be awkward in that case (if embedding is
possible at all).
Thanks
Janos
2008/10/1 Ulrich Stärk <[EMAIL PROTECTED]>
> Have a look at the If
> (
> http://tapestry.apache.org/tapestry5/ta
Have a look at the If
(http://tapestry.apache.org/tapestry5/tapestry-core/ref/org/apache/tapestry5/corelib/components/If.html)
and Zone
(http://tapestry.apache.org/tapestry5/tapestry-core/ref/org/apache/tapestry5/corelib/components/Zone.html)
components.
Uli
Am Mi, 1.10.2008, 17:06, schrieb Jáno
Sorry, I forgot that the tag is exactly for this :)
Cheers
Janos
2008/10/1 János Jarecsni <[EMAIL PROTECTED]>
> Hi guys,
>
> is there a way to change the template (piece of the template) which gets
> generated, depending on state? Here is what I mean:
> Given a component C, its C.tml looks like