You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Filip Balas <fb...@IMVProjects.com> on 2005/04/25 20:55:24 UTC

ActionLinks Looping in For problem...

I am using the T-Deli 'For' component to
dynamically create a list of editable items.
Now the form renders fine, I can add items
to it but when I try and click on any of the
actionlinks which I generated to remove or
save changes to the item in question, I recieve
the following error:

You have clicked on a stale link. 
Action id 1 does not match component ManageTitles/deleteTitle. 
This is most likely the result of using your browser's back button, but can also be an application error. 
You may continue by returning to the application's home page </phonelist/app?service=home>. 


Now I've looked at TiA, googled the net and tried
to find something on the mailing list but other people
are having a different problem than mine.  I am not having
problems with the form not rendering due to inconsistencies
between the number of form elements between requests
(this is the problem everyone is talking about).  My problem
seems to be that Tapestry is having trouble figuring out 
which link belongs to which listener...

Does anyone know where I could start looking for a solution
to this?

Filip


Re: Components and i18n

Posted by Erik Hatcher <er...@ehatchersolutions.com>.
On Apr 25, 2005, at 4:25 PM, Bruno Haas wrote:

> Hi All,
>
> From what I gather in the documentation, it is possible to inject a  
> localized string into a component by using the <message-binding> tag.  
> This is nice but let's say I have a component that takes an array of  
> strings as an input parameter. Would there be a way to somehow access  
> the pages .properties from the contained component ?
>
> In other words, I don't know beforehand the strings my component will  
> need to render or even how many there are and I would need the  
> localized strings to be obtained from outside the component.
>
> Have some of you faced the same problem ? How do you usually solve  
> this ?

All components (and pages are components) have access to the message  
resources.  <message-binding> is a convenience, but you can get  
directly at message resources through the API:

	http://jakarta.apache.org/tapestry/doc/api/org/apache/tapestry/ 
IComponent.html#getMessages()

You could pass in an array of message keys to your component, and  
access the parent page's messages using getPage().getMessages(), or you  
could resolve the messages from the page and pass the resolves strings  
into the component using the same mechanism.

	Erik


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


Components and i18n

Posted by Bruno Haas <gr...@laposte.net>.
Hi All,

 From what I gather in the documentation, it is possible to inject a 
localized string into a component by using the <message-binding> tag. 
This is nice but let's say I have a component that takes an array of 
strings as an input parameter. Would there be a way to somehow access 
the pages .properties from the contained component ?

In other words, I don't know beforehand the strings my component will 
need to render or even how many there are and I would need the localized 
strings to be obtained from outside the component.

Have some of you faced the same problem ? How do you usually solve this ?

Bruno

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