]
To: users@wicket.apache.org
Sent: Tuesday, September 23, 2008 10:48:54 PM
Subject: Re: Adding HTML class=invalid after validating with
IndicatingAjaxButton
target.addComponent(feedback);
target.addComponent(form); // you might have to add some div that is
around the form, not sure if browsers support
am asking for is not possible?
- Original Message
From: Igor Vaynberg [EMAIL PROTECTED]
To: users@wicket.apache.org
Sent: Tuesday, September 23, 2008 10:48:54 PM
Subject: Re: Adding HTML class=invalid after validating with
IndicatingAjaxButton
target.addComponent(feedback
)
{
tag.getAttributes().put(class,invalid);
}
}
}
- Original Message
From: Igor Vaynberg [EMAIL PROTECTED]
To: users@wicket.apache.org
Sent: Tuesday, September 23, 2008 5:50:08 PM
Subject: Re: Adding HTML class=invalid after validating with
IndicatingAjaxButton
public class
Thanks Martijn!!! That worked like a charm!
- Original Message
From: Martijn Dashorst [EMAIL PROTECTED]
To: users@wicket.apache.org
Sent: Thursday, September 25, 2008 1:59:41 PM
Subject: Re: Adding HTML class=invalid after validating with
IndicatingAjaxButton
Override onError too
I basically want to achieve this:
http://www.jroller.com/karthikg/entry/wicket_and_ajax
but handle the validation only after the form has been submitted with an
AjaxIndicatingButton instead of with the onblur as in the example.
I think I tried too many things over the last couple of days and got
public class invalidindicator extends abstractbehavior {
protected void oncomponenttag(component c, tag t) {
boolean valid=((formcomponent)c).isvalid();
if (!valid) {
tag.put(class,invalid);
}
}
}
formcomponent.add(new invalidindicator());
-igor
On Tue, Sep 23,
= ((FormComponent)component).isValid();
if(!valid)
{
tag.getAttributes().put(class,invalid);
}
}
}
- Original Message
From: Igor Vaynberg [EMAIL PROTECTED]
To: users@wicket.apache.org
Sent: Tuesday, September 23, 2008 5:50:08 PM
Subject: Re: Adding HTML class=invalid after
= ((FormComponent)component).isValid();
if(!valid)
{
tag.getAttributes().put(class,invalid);
}
}
}
- Original Message
From: Igor Vaynberg [EMAIL PROTECTED]
To: users@wicket.apache.org
Sent: Tuesday, September 23, 2008 5:50:08 PM
Subject: Re: Adding HTML class=invalid after
();
if(!valid)
{
tag.getAttributes().put(class,invalid);
}
}
}
- Original Message
From: Igor Vaynberg [EMAIL PROTECTED]
To: users@wicket.apache.org
Sent: Tuesday, September 23, 2008 5:50:08 PM
Subject: Re: Adding HTML class=invalid after validating