Hi!

On Thu, 21 Jul 2011 17:48:37 -0300, Josh Canfield <joshcanfi...@gmail.com> wrote:

I'm not sure how this helps the OPs problem though.

BeginRender for your component is going to happen after the layout
component has started rendering, and already output the title. Right?

Right!


<t:layout title="title">
<t:mycomponent title="title">
</t:layout>

t:mycomponent won't get a BeginRender until layout evaluates the <t:body/>

Yes, but in @AfterRender he will be able to use a little bit of DOM rewriting to change the page title if needed. ;)
If the title is given the "headTitle" id, it's just a matter of

void afterRender(MarkupWriter writer) {
        String newTitle = ...;
        Element element = writer.getDocument.getElementById("headTitle");
        element.removeChildren();
        element.text(newTitle);
}

--
Thiago H. de Paula Figueiredo
Independent Java, Apache Tapestry 5 and Hibernate consultant, developer, and instructor
Owner, Ars Machina Tecnologia da Informação Ltda.
http://www.arsmachina.com.br

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org

Reply via email to