Thiago H. de Paula Figueiredo wrote:
> 
> Em Thu, 27 Aug 2009 02:35:55 -0300, ThirstyCrow <5451vs5...@gmail.com>  
> escreveu:
> 
>> it works. However, the solution is still a little ugly. As you see, I  
>> have to manually split the parameter to get the page and block names. I  
>> tried the  two-parameter method: Object onAction(String page, String  
>> block), but
>> tapestry failed to call it.
> 
> Your context should be a List of strings, the page as the first element,  
> the block as the second. Thus, your onAction(String page, String block)  
> will be invoked.
> 
> -- 
> Thiago H. de Paula Figueiredo
> Independent Java consultant, developer, and instructor
> http://www.arsmachina.com.br/thiago
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
> For additional commands, e-mail: users-h...@tapestry.apache.org
> 

But how to express "a list of strings" in the template? The only way I know
is to join the strings with "/"s between them:
    <t:ActionLink context="literal:Index/content">Home</t:ActionLink>
The template above generates the following link:
   
http://localhost:8080/T5/index.globallayout.actionlink_0/Index$002fcontent
which cause the trouble. The "$002f" is indeed decoded back to "/", but it
seems the decoding happens later than the choice of event handler. Is this a
bug? Anyway, is there other ways to assign a list of strings to the context
attribute?

-- 
View this message in context: 
http://www.nabble.com/T5.1%3A-Get-block-by-%28page-and-block%29-names--tp25151389p25182304.html
Sent from the Tapestry - User mailing list archive at Nabble.com.


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

Reply via email to