You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by kshitiz <k....@gmail.com> on 2012/08/08 17:36:27 UTC
Image is not getting ajax refreshed in wicket 1.5
Hi,
I am simply displaying a captcha image which is suppose to refresh on
hitting a button:
* final String captchaValue = generateRandomString(30);
final NonCachingImage image = new NonCachingImage("image",
new CaptchaImageResource(captchaValue));
image.setOutputMarkupId(true);
AjaxFallbackButton ajaxRegisterSubmitButton = new AjaxFallbackButton(
"register", registerForm) {
protected void onSubmit(AjaxRequestTarget target, final Form<?> form) {
// some processing
if (target != null) {
image.setImageResource(new
CaptchaImageResource(generateRandomString(30)));
target.add(feedbackPanel);
target.add(image);
}
}
*
The code is simple...do I need to put CaptchaImageResource, image variables
as private class variabes?
--
View this message in context: http://apache-wicket.1842946.n4.nabble.com/Image-is-not-getting-ajax-refreshed-in-wicket-1-5-tp4651053.html
Sent from the Users forum 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: Image is not getting ajax refreshed in wicket 1.5
Posted by kshitiz <k....@gmail.com>.
Solved...actually my mistake...I was refreshing the image in onError
section...
--
View this message in context: http://apache-wicket.1842946.n4.nabble.com/Image-is-not-getting-ajax-refreshed-in-wicket-1-5-tp4651053p4651056.html
Sent from the Users forum 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