You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Nanda Firdausi <en...@spymac.com> on 2004/09/05 18:17:26 UTC

Form in a component

Hello all, 

I try to make a component. In the template, there are a form with some form
component. There is no problem until I try to submit the form. It always
sent a stale error. The message say that it found to little form component
inside. If I have 5 component there, then it will throw exception that it
need 5 more component, and so on.

I've try to debug some code from tapestry, and get a littel confuse with the
mechanism :P

I believe it is a bug... Can you solve it for me? If it is not a bug, what
should I do?

TIA

Nanda Firdausi



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


Re: Form in a component

Posted by Bryan Lewis <br...@maine.rr.com>.
It sounds like you're getting a StaleLinkException, probably because you
have a Conditional in your form that is omitting some of the components when
the page is rendered the second time.  Or maybe you have a Foreach list
that's empty the second time.

Chapters 3 and 4 of the Tapestry book have good discussions of this.  Also
check the Component Reference for FormConditional and ListEdit.  You might
also search the mailing list archives for "StaleLink".


----- Original Message ----- 
From: "Nanda Firdausi" <en...@spymac.com>
To: <ta...@jakarta.apache.org>
Sent: Sunday, September 05, 2004 12:17 PM
Subject: Form in a component


> Hello all,
>
> I try to make a component. In the template, there are a form with some
form
> component. There is no problem until I try to submit the form. It always
> sent a stale error. The message say that it found to little form component
> inside. If I have 5 component there, then it will throw exception that it
> need 5 more component, and so on.
>
> I've try to debug some code from tapestry, and get a littel confuse with
the
> mechanism :P
>
> I believe it is a bug... Can you solve it for me? If it is not a bug, what
> should I do?
>
> TIA
>
> Nanda Firdausi
>
>
>
> ---------------------------------------------------------------------
> 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


Re: Form in a component

Posted by Norbert Sándor <pr...@hotmail.com>.
You should ensure that when the form is being rendered and rewound, the same
components are rendered.
The simpliest solution may be to use ListEdit instead of Foreach and
FormConditional instead of Conditional.

As I written, please send the source of your component.

Bye,
Norbi

----- Original Message ----- 
From: "Nanda Firdausi" <en...@spymac.com>
To: <ta...@jakarta.apache.org>
Sent: Sunday, September 05, 2004 6:17 PM
Subject: Form in a component


> Hello all,
>
> I try to make a component. In the template, there are a form with some
form
> component. There is no problem until I try to submit the form. It always
> sent a stale error. The message say that it found to little form component
> inside. If I have 5 component there, then it will throw exception that it
> need 5 more component, and so on.
>
> I've try to debug some code from tapestry, and get a littel confuse with
the
> mechanism :P
>
> I believe it is a bug... Can you solve it for me? If it is not a bug, what
> should I do?
>
> TIA
>
> Nanda Firdausi
>
>
>
> ---------------------------------------------------------------------
> 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


Re: Form in a component

Posted by Norbert Sándor <pr...@hotmail.com>.
Please send some source.
Norbi

----- Original Message ----- 
From: "Nanda Firdausi" <en...@spymac.com>
To: <ta...@jakarta.apache.org>
Sent: Sunday, September 05, 2004 6:17 PM
Subject: Form in a component


> Hello all,
>
> I try to make a component. In the template, there are a form with some
form
> component. There is no problem until I try to submit the form. It always
> sent a stale error. The message say that it found to little form component
> inside. If I have 5 component there, then it will throw exception that it
> need 5 more component, and so on.
>
> I've try to debug some code from tapestry, and get a littel confuse with
the
> mechanism :P
>
> I believe it is a bug... Can you solve it for me? If it is not a bug, what
> should I do?
>
> TIA
>
> Nanda Firdausi
>
>
>
> ---------------------------------------------------------------------
> 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