You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by shumbola <sh...@yahoo.com> on 2007/10/01 09:10:56 UTC

Re: Stateless form submission

Igor,

How to use captcha on stateless form then? Is there a way I can detect
construction of page was either due to page reference or form submission?

Thank you!

shumbola


igor.vaynberg wrote:
> 
> yes, that is what stateless pages work. when you submit the whole page is
> recreated from scractch and the old state is applied.
> 
> -igor
> 
> 
> On 9/30/07, shumbola <sh...@yahoo.com> wrote:
>>
>>
>> I've got a class Register mounted at /app/register and a class
>> RegisterForm
>> extended from StatelessForm.
>> I put on this form two input fields, and a captcha from extensions. If I
>> submit then it calls constructor of Register class before onSubmit of
>> RegisterForm. Is that a normal behaviour? If I change my form to be
>> statefull, i.e., extend from Form class, submit directly goes to onSubmit
>> method.
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Stateless-form-submission-tf4543115.html#a12965003
>> Sent from the Wicket - User mailing list archive at Nabble.com.
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>> For additional commands, e-mail: users-help@wicket.apache.org
>>
>>
> 
> 

-- 
View this message in context: http://www.nabble.com/Stateless-form-submission-tf4543115.html#a12974326
Sent from the Wicket - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: Stateless form submission

Posted by shumbola <sh...@yahoo.com>.
Are you saying I've to add captcha to the panel and the panel to the
stateless form?
And have to add getStatelessHint() to my panel?
As far as I can see captcha from extensions is just an extension to the
DynamicImageResource and doesn't use session.


igor.vaynberg wrote:
> 
> afaict captcha cant be used on a stateless form because it needs to keep a
> token in session. i think that panel should have an overridden
> getstatelesshint() that returns false so that if you add it to the form it
> becomes stateful. try that and let me know if that helps.
> 
> -igor
> 
> On 10/1/07, shumbola <sh...@yahoo.com> wrote:
>>
>>
>> Igor,
>>
>> How to use captcha on stateless form then? Is there a way I can detect
>> construction of page was either due to page reference or form submission?
>>
>> Thank you!
>>
>> shumbola
>>
>>
>> igor.vaynberg wrote:
>> >
>> > yes, that is what stateless pages work. when you submit the whole page
>> is
>> > recreated from scractch and the old state is applied.
>> >
>> > -igor
>> >
>> >
>> > On 9/30/07, shumbola <sh...@yahoo.com> wrote:
>> >>
>> >>
>> >> I've got a class Register mounted at /app/register and a class
>> >> RegisterForm
>> >> extended from StatelessForm.
>> >> I put on this form two input fields, and a captcha from extensions. If
>> I
>> >> submit then it calls constructor of Register class before onSubmit of
>> >> RegisterForm. Is that a normal behaviour? If I change my form to be
>> >> statefull, i.e., extend from Form class, submit directly goes to
>> onSubmit
>> >> method.
>> >>
>> >> --
>> >> View this message in context:
>> >>
>> http://www.nabble.com/Stateless-form-submission-tf4543115.html#a12965003
>> >> Sent from the Wicket - User mailing list archive at Nabble.com.
>> >>
>> >>
>> >> ---------------------------------------------------------------------
>> >> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>> >> For additional commands, e-mail: users-help@wicket.apache.org
>> >>
>> >>
>> >
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Stateless-form-submission-tf4543115.html#a12974326
>> Sent from the Wicket - User mailing list archive at Nabble.com.
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>> For additional commands, e-mail: users-help@wicket.apache.org
>>
>>
> 
> 

-- 
View this message in context: http://www.nabble.com/Stateless-form-submission-tf4543115.html#a12983178
Sent from the Wicket - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: Stateless form submission

Posted by Igor Vaynberg <ig...@gmail.com>.
afaict captcha cant be used on a stateless form because it needs to keep a
token in session. i think that panel should have an overridden
getstatelesshint() that returns false so that if you add it to the form it
becomes stateful. try that and let me know if that helps.

-igor

On 10/1/07, shumbola <sh...@yahoo.com> wrote:
>
>
> Igor,
>
> How to use captcha on stateless form then? Is there a way I can detect
> construction of page was either due to page reference or form submission?
>
> Thank you!
>
> shumbola
>
>
> igor.vaynberg wrote:
> >
> > yes, that is what stateless pages work. when you submit the whole page
> is
> > recreated from scractch and the old state is applied.
> >
> > -igor
> >
> >
> > On 9/30/07, shumbola <sh...@yahoo.com> wrote:
> >>
> >>
> >> I've got a class Register mounted at /app/register and a class
> >> RegisterForm
> >> extended from StatelessForm.
> >> I put on this form two input fields, and a captcha from extensions. If
> I
> >> submit then it calls constructor of Register class before onSubmit of
> >> RegisterForm. Is that a normal behaviour? If I change my form to be
> >> statefull, i.e., extend from Form class, submit directly goes to
> onSubmit
> >> method.
> >>
> >> --
> >> View this message in context:
> >>
> http://www.nabble.com/Stateless-form-submission-tf4543115.html#a12965003
> >> Sent from the Wicket - User mailing list archive at Nabble.com.
> >>
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> >> For additional commands, e-mail: users-help@wicket.apache.org
> >>
> >>
> >
> >
>
> --
> View this message in context:
> http://www.nabble.com/Stateless-form-submission-tf4543115.html#a12974326
> Sent from the Wicket - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>